Does OnData on Minute timeframe not get called with hourly consolidators are used in onSecurityChanges
QUANTCONNECT COMMUNITY
Does OnData on Minute timeframe not get called with hourly consolidators are used in onSecurityChanges
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.
Mia Alissi
Here’s an explanatory example and answer for Manoj's question:
No, using hourly consolidators (even when attached in OnSecurityChanges) does NOT change how often OnData is called. OnData still runs for every bar of your data subscription’s resolution (e.g., every minute for minute data). Consolidators let you process aggregated data, but do not modify the data subscription frequency.
Below is an example with comments:
Key points for Manoj:
Let me know if you’d like an example that dynamically adds/removes consolidators in OnSecurityChanges!
Sources: Time Period Consolidators - QuantConnect.com, Data Consolidation Algorithm, Mixed-Mode Consolidators - QuantConnect.com, Futures Fast Trend Following, with Trend Strength, Manually Removed Consolidators Algorithm
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.
Manoj Kandlikar
Sure please show example on dynamically adds/removes consolidators in OnSecurityChanges. It does not work when I add symbols dynamically using Coarse and Fine universe , and at the same time have AddEquity ("SPY", Resolution.Minute) in initialize() . I am not getting OnData being called on Minute timeframe.Â
Manoj Kandlikar
@mia can you respond
Manoj Kandlikar
This seems to be related to Quantconnect not being able to handle Equities and Indexes being pumped at the same time, Indexes get pumped initially , and after that Equities are the only once that get pumped
Manoj Kandlikar
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!