Skip to content

Commit e28d05e

Browse files
committed
document how to backtest quickly
1 parent b00a13d commit e28d05e

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,25 @@ http://cryptobot-sample-logs.azulinho.com:5555/
6464
Don't decompress these files, as the bot consumes them compressed in the lz4
6565
format.
6666

67+
Processing each daily logfile takes around 30 seconds, so for a large number of
68+
price log files this can take a long time to run backtesting simulations.
69+
A workaround is to test out each coin individually by generating a price.log
70+
file containing just the coins we care about.
71+
72+
```
73+
rm -f MYCOINS.log
74+
for ta in logs/2021*.lz4
75+
do
76+
lz4cat ${ta} | egrep -E 'BTCUSDT|ETHUSDT|BNBUSDT|DOTUSDT'>> MYCOINS.log
77+
done
78+
lz4 MYCOINS.log
79+
80+
```
81+
82+
and then use that *MYCOINS.log.lz4* in the PRICE_LOGS configuration setting.
83+
This way each simulation takes just a few seconds.
84+
85+
All backtests are logged into log/backtesting.log.
6786

6887
## Riot/Matrix:
6988

0 commit comments

Comments
 (0)