I am just getting started with QuantConnect, and am loving it, but I have run into an issue with a rather simple set-up. A backtest is providing me with some unrealistic gains during a 2-week period in May 2021.
I am using a very simple entry strategy. Essentially RSI < 30, and exiting at 2% target gains and 1% stop loss (clearly not a real strategy, but just familiarising myself). For some reason in May the PNL amounts no longer make any sense. The buy and sale prices are still correct (I am logging those), but then when I log the profits attached to each trade, they just don't tally up. Sometimes it says 0, but then for a few days the profits attached to each trade are unrealistically high.
Am I missing something? What would be the best approach to debug this issue?
Varad Kabade
Hi Koen Dirckx,
To debug the above backtest, we can plot the security price at the end of the day to see the price movement if it is consistent with our results. We can also use debugger tool to aid in debugging any strategy.
Refer to the attached backtest.
Best,
Varad Kabade
Koen Dirckx
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!