Skip to main content

Volatility Breakout with Bollinger Bands for Amibroker (AFL)

kaiji over 16 years ago Amibroker (AFL)

  • Rating:
    5 / 5 (Votes 1)
  • Tags:
    trading system, amibroker, exploration, volatility

This Trading system gives buy and short signals when after Bollinger Bands got very narrow they spread out and the Close touches the band (top or bottom). Additionally the MFI has to confirm this volatility breakout. But please be carefull because some stocks suddenly change direction and in this case they really change! For more information please read “Bollinger on Bollinger Bands”.

Indicator / Formula

Copy & Paste Friendly
Band= (BBandTop( C, 20, 2 ) - BBandBot( C, 20, 2)) / MA(Close, 20 ) * 100;
B= ((Close - BBandBot( Close, 20, 2 )) / (BBandTop( Close, 20, 2 ) - BBandBot(Close, 20, 2 ))) * 100;

Buy = band < 15 AND b > 95 AND MFI(10) > 60;
Sell = Cross(Close,SAR(0.01,0.2));
Short = band < 15 AND b < 5 AND MFI(10) < 40;
Cover = Cross(SAR(0.01,0.2), Close);

Filter = (band < 15 AND b > 95 AND MFI(10) > 60)  OR (band < 15 AND b < 5 AND MFI(10) < 40);

NumColumns = 1;
Column0 = Close;

1 comments

almost 9 years ago

When +DMI cross -DMI and first bar close above mid
Bollinger Band Then buy at Cross of Bar High

Remember most Important thing

Bar that close above mid BB is important

See that the close is within 15% of bar high and not less

Suppose Bar High is 100
Bar low is 90
Then Difference is 10

So 15% of 10 is 1.5

High – 1.5 = 100 – 1.5 = 98.50

So Close must be above 98.50

DMI VALUES ARE 14
BOLLINGER BAND (20,2)

hello ,sir how to write this in AFL i am a new in afl programming

Leave Comment

Please login here to leave a comment.