Hi, 

I am attempting to use the MACD indicator with a consolidator but am having trouble. In my Initialize() function i have:

        self.macd = self.MACD(self.my_ticker, 12, 26, 9, MovingAverageType.Exponential, Resolution.Minute)         self.macd_cons = TradeBarConsolidator(timedelta(minutes=10))         self.macd_cons.DataConsolidated += self.macdUpdated         self.SubscriptionManager.AddConsolidator(self.my_ticker, self.macd_cons)         self.RegisterIndicator(self.my_ticker, self.macd, self.macd_cons)

and in the same class, the helper function:

    def macdUpdated(self,sender,bar):         if self.macd.Current.Value >= self.macd.Signal.Current.Value:             self.Debug("[+] above {} {} {} ".format(self.Time, self.macd.Current.Value, self.macd.Signal.Current.Value))         else:             self.Debug("[-] below {} {} {} ".format(self.Time, self.macd.Current.Value, self.macd.Signal.Current.Value))

The prices I see (when compared against Charles Schwab's) are somewhat similar. I am aware of your FAQ regarding prices. However, the ten minute MACD that CS provides versus this one has completely different data, which leads me to believe I'm doing something wrong. The output below is from 11 to 1 on a random day. This link 

https://imgur.com/a/urcPQP0

is from CS for the same time. For instance, the MACD at 1230, according to CS, is around .043, while at 11:30 it is .026. But more importantly, the MACD line is always above the signal line from 11 to 1 according to CS, which is not the case in the data below. I am not 100% sure CS uses EMA for their MACD lines but https://help.streetsmart.schwab.com/edge/1.6/Content/Chart%20Studies.htm seems to say they do. Trying on QuantConnect with different MovingAverageType didn't change the differences between the two. 

[+] above 2021-02-03 11:00:00 0.01086282153091968 0.01043351510466672
[+] above 2021-02-03 11:10:00 0.017115039083645686 0.013846390720055628
[-] below 2021-02-03 11:20:00 0.004363630117023701 0.008898289604792024
[+] above 2021-02-03 11:30:00 0.004280274735000386 0.002952826515702166
[+] above 2021-02-03 11:40:00 0.009948153148334535 0.007532968454340619
[+] above 2021-02-03 11:50:00 0.014130897930721201 0.010762260173893637
[-] below 2021-02-03 12:00:00 0.01618329286993292 0.016434888114781054
[-] below 2021-02-03 12:10:00 0.008510039349490243 0.011037537106545658
[-] below 2021-02-03 12:20:00 0.002854144002440724 0.004979843427408466
[-] below 2021-02-03 12:30:00 0.0003614507231492533 0.001764756038148813
[-] below 2021-02-03 12:40:00 -0.0002237201709032017 7.342287373448871e-05
[+] above 2021-02-03 12:50:00 0.009090660517783726 0.004878490081079443
[-] below 2021-02-03 13:00:00 0.003567513368485681 0.004957401141400548

 

Thanks for your help