Improving backtesting speed
Improving backtesting speed
22 Aug 2024, 18:49
I'm just moving to CTrader from my own bare-bones trading platform. It's also authored in C#, but the backtester is far faster - especially with ticks.
I spent a couple of days studying CLR optimisation and achieved excellent results by profiling hotspots, reducing boxing and allocations etc. It wasn't a big project.
I've also been working with Zorro, which again is significantly faster.
Please give this some attention! There are surely gains to be made?
Replies
scotpip
23 Aug 2024, 11:02
RE: Improving backtesting speed
Hi Panagiotis
My backtester is fairly comparable, and as I say a lot faster. The speed increase was mainly due to tackling a large number of small issues, but the cumulative effect was impressive.
I was also a beta tester for Tickblaze, another C# platform that's faster. Tickblaze is a professional trading platform and highly featured.
And I've done some work in Zorro - which is highly featured and very much faster - though to be fair it's built in C++.
Are you really saying there's no scope for increasing the speed?
@scotpip
PanagiotisCharalampous
23 Aug 2024, 13:42
RE: RE: Improving backtesting speed
scotpip said:
Hi Panagiotis
My backtester is fairly comparable, and as I say a lot faster. The speed increase was mainly due to tackling a large number of small issues, but the cumulative effect was impressive.
I was also a beta tester for Tickblaze, another C# platform that's faster. Tickblaze is a professional trading platform and highly featured.
And I've done some work in Zorro - which is highly featured and very much faster - though to be fair it's built in C++.
Are you really saying there's no scope for increasing the speed?
Performance improvements are always within the scope of every release. Can you share your backtester?
@PanagiotisCharalampous
PanagiotisCharalampous
23 Aug 2024, 06:49
Hi there,
Is your backtester equivalent to cTrader i.e. handles all necessary calculations, like margin calculation, conversions between currencies etc. If it is not, then the comparison is not really valid.
Best regards,
Panagiotis
@PanagiotisCharalampous