7 ms·
that's pretty cool, thanks very much for sharing this! just had a quick scan through the code and it looks there's one thing missing (apologies if not as I hav
by bjoerns 13y ago
that's pretty cool, thanks very much for sharing this!
just had a quick scan through the code and it looks there's one thing missing (apologies if not as I haven't had the time yet to really run the code). if you actually want to create a tradable backtest you have to bear in mind that you are selling/buying during the roll period meaning that if you invest amount x before rolling over what you end up with after the roll is not equal to the value of your perpetual series.
to give you a simple example: if you roll over 1 day only and CLG14 settles at t1=100, t2=110 and CLH14 settles at t1=90, t2=95 your position after the roll is worth 105.56 (not 95).
makes sense?