Durbtrade Bollinger Bands Width

First published script. Actually, this is my 1st script ever! I know its not flashy or anything, but I finally decided to try learning some pine... and to try and get rid of the dang 0 on my profile, haha. So here are the results after many hours.

I like using the BB Width indicator, and I wanted it to change color based on whether is was rising or falling. I also have it to automatically plot a horizontal line at 0 so I don't have to draw a line every time I apply the indicator to a new chart. And I changed the default precision to 3.

I noticed that there aren't that many BB Width scripts. and I don't think there is anything like this out there that I know of, so I hope someone else besides me will find it useful.

Please feel free to comment.
Release Notes: Update... plots an optional EMA of the BBW behind the BBW. Additional changes were made to the default color and line thickness. And finally I changed the script name to be found more easily during indicator searches.
Release Notes: More name changes.
Release Notes: Modified the zero line - now it doesn't extend to the edge of the window, keeping the indicator a bit cleaner. Also added extra options to customize the lines appearance.
Release Notes: Now has the option to show customizable, color-coded, cross-over and cross-under background fills... signaling when the BBW crosses the EMA.
Release Notes: A color fill option is now included if you would like to fill the spaces between the BBW and BBW EMA lines with 2 customizable colors and opacities depending on if the BBW is above or below the BBW EMA, for increased information/clarity.
Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

Want to use this script on a chart?


Well, I tried to change the name to make searches easier... didn't work. Lesson learned.
+1 Reply
Cool thanks! I like having the color change on this because I usually keep the bb width indicator squashed pretty short on my main chart. Helps to discern the movements using less real estate. I want to add a 50ema of the bb width to this script.
+1 Reply
Hi! It looks good on 1D with length 27. It remids me this one CM_Ultimate RSI MTF from ChrisMoody (FastLength=12, SlowLength=29, SignalLengh=2). Take a look.
+1 Reply
Here is a little secret that you may or may not already know about the Durbtrade BBW... sometimes, depending on factors such as volatility, timeframe, and indicator height, you may notice the bbw line alternating between red and green relatively quickly... I call this a "sparkle". This usually happens before a major move (typically upward) of the bbw, which, in turn, happens when there is a major change in price. When you see it "sparkling", take a look at the macd for indications of the direction of the upcoming price action (up or down). So yeah, if you see it sparkle, there's a pretty good chance that a significant price change is about to occur!


// Durbtrade

If you like this style, also check out the Durbtrade MACD:
Durbtrade Durbtrade
@Durbtrade, as well as the Durbtrade Triple RSI

Durbtrade Durbtrade
@Durbtrade, and the Durbtrade Stoch RSI