+91-0000000000

}

Monday – Friday : 9:00 AM – 6:30 PM

Bolinger bands and ADX

Bollinger Bands, an indicator in Amibroker AFL, help gauge market volatility and price levels. They consist of a moving average and two bands above and below it, representing volatility. When paired with ADX (Average Directional Index), traders gain insights into the strength of a trend. ADX measures trend strength without considering its direction. Combining both tools, traders can identify periods of high volatility, potential trend reversals, and the strength of ongoing trends. 

/_SECTION_BEGIN("heiken-ashi-bolinger-bands-and");
//================================================== ======================
// HBA Trading system (Heiken Ashi, Bolinger Bands, ADX)
// AFL by HuyNQ. (SRSR 4rum member)
//================================================== ==================================
SetChartOptions(0,chartShowArrows | chartShowDates);

// 1. Heiken Ashi
HaClose = (O + H + L + C)/4;
HaOpen = AMA( Ref( HaClose, -1 ), 0.5 );
HaHigh = Max( H, Max( HaClose, HaOpen ) );
HaLow = Min( L, Min( HaClose, HaOpen ) );
xDiff = (HaHigh - Halow);
barcolor = IIf(HaClose >= HaOpen,colorBrightGreen,colorRed);
PlotOHLC( HaOpen, HaHigh, HaLow, HaClose, "", barcolor, styleCandle );

// 2. Bolinger Bands
BBTop=BBandTop(H,10,2);
BBBot=BBandBot(L,10,2);
BBMid=(BBTop+BBBot)/2;

Plot(BBTop,"",12,1);
Plot(BBMid,"",12,1);
Plot(BBBot,"",12,1);


// Buy, sell
EntryLong = Cross(C,BBMid) AND HaClose>HaOpen AND xDiff>1 AND ADX(14)<40;
ExitLong = Cross(BBMid,C) AND HaClose1;
PlotShapes(IIf(EntryLong , shapeSmallUpTriangle, shapeNone) ,colorBrightGreen, 0,L,-30);
PlotShapes(IIf( ExitLong , shapeSmallDownTriangle, shapeNone) ,colorOrange, 0,H,-25);
_SECTION_END();

Open chat
1
Hi, how can I help you?