Hey just a question about indicators;
When I add a security(e.g. SPY) as, let's say, Resolution.Daily, I assumed that when I add a corresponding indicator for that security, the default Resolution would also be Daily(assuming I leave that parameter blank when adding the Indicator.)
e.g. I assumed that:
self.RSI("SPY", 14)
would technically default to:
self.RSI("SPY", 14, Resolution.Daily)
But when I decided to include the Resolution parameter when adding the indicator(so that it is now self.RSI("SPY", 14, Resolution.Daily)), the backtest results are now different; I seem to be obviously missing something, I was hoping someone could help me out with this.
Shile Wen
If the security is added with Daily resolution, then
self.RSI("SPY", 14, MovingAverageType.Wilders, Resolution.Daily)
and
self.RSI("SPY", 14)
is the same, because the default resolution is the subscriptions resolution and the default moving average is Wilders.
We have an open issue in GitHub because of the ambiguity:
Optional Parameter in Indicator Helpers Sets Wrong Values in Python #4491
Best,
Shile Wen
Vncne
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!