Backtest with Paper Trading, if Equity Curve goes down a certain amount

Hi everybpdy,

I would like to backtest a rotational strategy with backtester combined with papertrading periods during larger drawdowns of the equity curve based on EOD trades.

One of my simulations I tried is to run the rotational backtest as first step and get the white equity curve in the graphic below. Then I take this equity curve with my indicator for real trading periods versus paper trading periods and use this indicator and go through the normal trade list generatetd in the first step and do a second step with analyzing/summing up all trades not belonging to the paper trading periods (for ( trade = bo.GetFirstTrade( ); trade; trade = bo.GetNextTrade( ))) . So this is my optimized list of trades without the paper trades. Based on that i generate an optimized Equity curve. This is the yellow curve below.

This works, but unfortunately I was not able to sell all my open trades at the day of the switch to papertrading. And further more I would like to reenter the market when the original equity curve goes up again (stop restart real trading) and buy every symbol, which is open based on the original tradelist. The resulting curve should look like the orange curve below.
image

So, I guess that the only way to do that ist to use the low level backtester interface.
Is that correct or has anybody another idea or strategy which works with standard backtester (high level) capabilities/strategy?

Kind regards
Alex

Hi everybody,
as there was no response till now to my question above:

Is it too difficult to understand or the question not specific enough?
Or was it already covered and I didn't find the answer?
Or is it too silly?

Any feedback would be appreciated.

Kind regards
Alex

If you're running a rotational strategy, then why not just incorporate the information from the full equity curve (which I assume you've saved to the database) into your PositionScore for the optimized backtest?

1 Like

Hi mradtke,

thank's a lot for answering so quick.

That was one of my ideas, but I was a little bit hesistant to try it as for that I guess I would need a two step approach with a batch prcess or maybe with a sequence. First step doing a regular backtest and in the second step performing a backtest with the equity curve and my indicator.

But if an expert like you would do it this way I will check that out next weekend.
I am very curious if I get it working. I will update you.

Thnaks again
Alex

Yes, the easiest way is to run two backtests: one with all the trades to establish the equity curve, and a second one that has different trade entries and exits based on the first equity curve.

1 Like

Thanks a lot once more :smiling_face:

In the meantime I got it working with the two step approach.
But optimization of parameters is a little bit laborious compared to a single step backtest. But it works and the result looks promising.

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.