//------------------------------------------------------ // // Formula Name: Acceleration Bands // Author/Uploader: Trading Tuitions // E-mail: support@tradingtuitions.com // Website: www.tradingtuitions.com //------------------------------------------------------ _SECTION_BEGIN("Acceleration Bands"); SetChartOptions(0,chartShowArrows|chartShowDates); _N(Title = StrFormat("{{NAME}} – {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) )); Plot( Close, "Price", colorWhite, styleCandle ); LookbackPeriods = Param("LookbackPeriods",20,5,100,5); range=(H-L)/(H+L)/2; Upperband=MA(H*(1+2*((2*range)*100)*.01),LookbackPeriods); Lowerband= MA(L*(1-2*((2*range)*100)*.01),LookbackPeriods); Middleband=MA(C,LookbackPeriods); Plot(Upperband, "Upper Band",colorBlue,styleLine); Plot(Middleband, "Middle Band",colorWhite,styleLine); Plot(Lowerband, "Lower Band",colorRed,styleLine); _SECTION_END();