Processing time of backtests on a single computer
On Thu, Apr 7, 2016 at 8:10 AM, Jersey Fanatic <jerseyfanatic1 at gmail.com> wrote:
10 years of daily data makes about 2500 data points. So extrapolating from that to 58000 data points (assuming the relation is linear), it should take
Number of data points is not necessarily a good estimator for run time even if the strategies are the same. What matters more is the number of timestamps/observations that must be evaluated. That includes signals, moving orders, processing fills, etc.
about 12.2 secs for a single run with my dataset. For 144 runs (total number of parameter combinations), it should take about 30 mins. However, I
Again, the relationship is not linear. Different parameter combinations will produce differing amounts of signals, order movement, fills, etc. For example, I ran parameter optimization on ~3 years of 5-second data. Some parameter combinations took 1-2 minutes, some took >20 minutes.
ran apply.paramset() this morning (without trailing stops), it took 4.5 hours. And the code is the one that I sent earlier with Trailing stop rules enabled=FALSE'd. Did you run the macd demo code with single core? If you did some parallel processing, did you use doSNOW package or something else? Maybe that is the reason, I am not sure. Would deleting trailing stop rules speed things up, instead of defining them but setting enabled=FALSE? 2016-04-07 0:34 GMT+03:00 Brian G. Peterson <brian at braverock.com>:
On Wed, 2016-04-06 at 23:58 +0300, Jersey Fanatic wrote:
I will try running the same code without trailing stops and see what effect it has on the processing time. I will report back as soon as it is finished.
Running the macd demo code over 10 years of daily data on my machine (no trailing stops) takes 0.5262365 secs for a single run.
[[alternative HTML version deleted]]
_______________________________________________ R-SIG-Finance at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-finance -- Subscriber-posting only. If you want to post, subscribe first. -- Also note that this is not the r-help list where general R questions should go.
Joshua Ulrich | about.me/joshuaulrich FOSS Trading | www.fosstrading.com R/Finance 2016 | www.rinfinance.com