I attempted at trading a list of equities but I was wondering if I am missing some pieces of code or if some things are not working in the code such as:
1. Is my code storing each securities' rolling window individually
2. Is the code buying the individual security when the specific pattern happens
3. Is the code issuing the stop loss and profit taking mechanism individually for each security?
4. What am I missing? What do I need to get rid of?
I know it is a complex code but my main points of emphasis are what I wrote above.
Douglas Stridsberg
Hey Nicholas,
As discussed over Slack and in case anyone else stumbles upon this thread, here's a few pointers:
def TradeBarHandler(self, TradeBar): self.Windows[TradeBar.Symbol].Add(TradeBar)
Going further down your code, you'd obviously have to rewrite all references to self.Window[x] to self.Windows[Symbol][x]. Implementing those changes would at least get the window consolidation up to speed. Then I don't know if the rest of the code works as intended, but that's based on what rules you want the trading to follow.
Nicholas Stern
Thanks Douglas
Nicholas Stern
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!