Stock Portfolio Organizer
The ultimate porfolio management solution.
WiseTrader Toolbox
#1 Selling Amibroker Plugin featuring:
Trend detection bands for Amibroker (AFL)
interesting, just that
disabeld are upper/lower bands. Over are the middle bands, which form a wave, and can be used for
trend direction.
drag over a price-chart
Screenshots
Similar Indicators / Formulas
Indicator / Formula
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 | _SECTION_BEGIN ( "_trend detection bands (overlay)" ); BDay= Optimize ( "upper-lines" , Param ( "upper-lines" ,1,1,28,1),1,21,1); //2 SDay= Optimize ( "lower-lines" , Param ( "lower-lines" ,1,1,28,1),1,21,1); //7 Hc=( O + H + L + C )/4; Ho = AMA ( Ref ( Hc, -1 ), 0.5 ); Hh = Max ( H , Max ( Hc, Ho ) ); Hl = Min ( L , Min ( Hc, Ho ) ); HHb = HHV (hH,Bday); HCb = HHV (hC,Bday); LLb = LLV (hL,Bday); LCb = LLV (hC,Bday); HHs = HHV (hH,Sday); HCs = HHV (hC,Sday); LLs = LLV (hL,Sday); LCs = LLV (hC,Sday); for ( i = 1+ Max (Bday,Sday); i < BarCount ; i++ ) { if ((HHb[i-1] - LCb[i-1]) >= (HCb[i-1] - LLb[i-1])) Buyrange[i] = HHb[i-1] - LCb[i-1]; else Buyrange[i] = HCb[i-1] - LLb[i-1]; if ((HHs[i-1] - LCs[i-1]) >= (HCs[i-1] - LLs[i-1])) Sellrange[i] = HHs[i-1] - LCs[i-1]; else Sellrange[i] = HCs[i-1] - LLs[i-1]; }; Band_TopSMOOTH= AMA ( Ho+Buyrange, 0.5 ); Band_BotSMOOTH= AMA ( Ho-Sellrange, 0.5 ); Band_MidSMOOTH=(Band_TopSMOOTH+Band_BotSMOOTH)/2; Band_Top=Ho+Buyrange; Band_Bot=Ho-Sellrange; Band_Mid=(Band_Top+Band_Bot)/2; BS = ParamToggle ( "bands smooth" , "No|Yes" ,1); BN = ParamToggle ( "bands normal" , "No|Yes" ,1); DUL = ParamToggle ( "upper/lower bands" , "No|Yes" ,0); //disable upper/lower bands if (BS AND DUL) Plot ( Band_TopSMOOTH, " Band_TopSMOOTH " , IIf ( Band_TopSMOOTH> Ref (Band_TopSMOOTH,-1), colorOrange , colorRed )); if (BS) Plot ( Band_MidSMOOTH, " Band_MidSMOOTH " , IIf ( Band_MidSMOOTH> Ref (Band_MidSMOOTH,-1), colorGreen , colorRed )); if (BS AND DUL) Plot ( Band_BotSMOOTH, " Band_BotSMOOTH " , IIf ( Band_BotSMOOTH> Ref (Band_BotSMOOTH,-1), colorDarkGreen , colorGreen )); if (BS) Plot ( 1, "ribbon" , IIf ( Band_MidSMOOTH> Ref (Band_MidSMOOTH,-1), colorGreen , IIf ( Band_MidSMOOTH< Ref (Band_MidSMOOTH,-1), colorRed , colorPink )), styleOwnScale | styleArea | styleNoLabel , -0.5, 100 ); if (BN AND DUL) Plot ( Band_Top, " Band_Top " , IIf ( Band_Top> Ref (Band_Top,-1), colorOrange , colorRed )); if (BN) Plot ( Band_Mid, " Band_Mid " , IIf ( Band_Mid> Ref (Band_Mid,-1), colorGreen , colorRed )); if (BN AND DUL) Plot ( Band_Bot, " Band_Bot " , IIf ( Band_Bot> Ref (Band_Bot,-1), colorDarkGreen , colorGreen )); if (BN) Plot ( 2, "ribbon" , IIf ( Band_Mid> Ref (Band_Mid,-1), colorGreen , IIf ( Band_Mid< Ref (Band_Mid,-1), colorRed , colorPink )), styleOwnScale | styleArea | styleNoLabel , -0.5, 100 ); _SECTION_END (); |
2 comments
Leave Comment
Please login here to leave a comment.
Back
this chart is simple alredy some afl avyalable inthis type
Thnaks