I want to use Triangular Moving Average with S&P 500 Futures.

Since we are using Futures, we can't set up the Indicator to be automatically updated in the Initialize function because... Futures.

In the OnData method, we use the Update method to pump data into the Triangular Moving Average indicator.

The Update method expects an IndicatorDataPoint (yet, programatically, a TradeBar is more intuitive).

Once I get a TradeBar, I create an IndicatorDataPoint and pump the Triangular Moving Average with the IndicatorDataPoint.

My question is... Is there a better way? What is the "QuantConnect" (optimal) way to get the TradeBar of the front month and an IndicatorBasePoint for pumping indicators?

Author