Hi,

I am trying to get the simple moving average of the High and low for past 8 day,then store them in the rolling window.

In rolling window i am storing the daily level trade bar,sma of 8 High and low.

I would like to know if am finding the sma correctly ,as it is not matching to the sma as shown over other website like Trading view,Investing.com.

2)Also i would like to know why there is no need to create a seperate method for saving the daily level trade details(as it is directly used on    def ondata()) as compared to sma.

Author