bunti ji can you please share the afl for which pics are uploaded /??
_SECTION_BEGIN("trend with pivot levels");
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
TimeFrameSet(inDaily);
wc=C;
TimeFrameRestore();
uptrend= Signal(18)<MACD(7);
downtrend= Signal(18)>MACD(7);
PRSI=RSI(14)>55 ;
NRSI=RSI(14)<45 ;
Plot( 2, /* defines the height of the ribbon in percent of pane width */"ribbon",
IIf( PRSI, colorGreen, IIf( NRSI, colorRed, 0 )), /* choose color */
styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_BEGIN("Chart");
MASK= ParamStyle("MASK",styleCandle| styleThick , maskAll);
barcolor=IIf(UPTREND,colorGreen,IIf(doWNTREND,colorRed,colorBlue));
Plot(C, "C", barcolor,MASK);
A=C>MA(C,50) ;
B=C<MA(C,50) ;
Plot( 2, /* defines the height of the ribbon in percent of pane width */"ribbon",
IIf( A, colorGreen, IIf( B, colorRed, 0 )), /* choose color */
styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_END();
_SECTION_BEGIN("MA 50");
A=C>MA(C,50) ;
B=C<MA(C,50) ;
Plot( 4, /* defines the height of the ribbon in percent of pane width */"ribbon",
IIf( A, colorBlue, IIf( B, colorRed, 0 )), /* choose color */
styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_END();
t=Param("t", 22, 1, 5000, 1);
/*Top = Sum(High, t) / t;
Bottom = Sum(Low, t) / t;
*/
Top = EMA(High, t) ;
Bottom = EMA(Low, t);
av=(Top+Bottom)/2;
mc=IIf(av>C, ParamColor("Trigger line Up Color", colorGold), ParamColor("Trigger line Dn Color", colorBlue));
Plot(av, "\nTrigger : ", mc, ParamStyle("Trigger line Style",styleStaircase,maskAll),0,0,0,9);