Back

[backtest] [charting] duplicate datapoint with warmup set

Discovered an odd feature/bug when warmup period is requested - we get a duplicate datapoint at the beginning of our requested startDate. Run the attached backtest and verify duplicate from logs. Note if line #14 is commented out (warmup setup), it no longer reproduces; neither does it happen with warmup disabled and startDate moved back to 25th.

Looking at the fxcm eurusd minute data between 25th & 26th of June, no duplicates can be spotted.

Also the log confirms duplicate is at 1561507140 (which translates to Tue 25 Jun 2019 11:59:00 PM UTC); yet when we plot said data and consume from the ZMQ, the duplicate timestamp now reads 1561521600 (Wed 26 Jun 2019 04:00:00 AM UTC). All times should be UTC right, so where is this discrepancy creeping in from?

Update Backtest








0

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.


Hey Laur,

Thanks for pointing that out! It seems to be a bug with LEAN. We've opened up a Github Issue for this.

0

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.


Good stuff!
Can you comment on the timestamp discrepancy though - my understanding is the clocks are all UTC, meaning duplicate datapoint in the ZMQ charting message should still have the same timestamp of 1561507140.

0

Hey Laur,

I'm not able to reproduce the behavior you are talking about. Could you post a backtest that produces it? It would be greatly appreciated it.

Thanks
Rahul

0

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.


Update Backtest





0

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.


Loading...

This discussion is closed