Back

Where do I handle generated Insights to use to execute orders?

Hi, new user here. I am building my AlphaModel in my algorithm and so far have my own way of generating up and down insights within my AlphaModel's Update() method. Where in my code should I handle those insights to use to make orders?

Do I handle this within my main class' OnData() method?

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.


Hi Jamie, 

if you are using the Algorithm Framework, you don't need the OnData() method. The Update() method within your AlphaModel can be seen as a replacement for the OnData() method when using the Framework. 

The AlphaModel sends the generated insights to the Portfolio Construction Model, so you can handle your insights in the PCM class. There is a method

CreateTargets(self, algorithm, insights)

 

 

2

Expanding on Arthur's answer, the Execution Model is the final one that makes orders but PCM is where insights are managed.

Insights (Alpha Model) -> Optimal Quantity/Weights (Portfolio Model) -> Risk-adjusted Quantity/Weights (Risk Model) -> Make orders to hit the targets (Execution)

 

 

 

2

Thank you guys for the information. I'll see how it goes!

1

Thank you for pointing this out Adam and Arthur. I dug some more and found this diagram illustrating exactly what you guys are saying for anyone else stumbling into this same problem.111173_1596902895.jpg

2

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