OPEN-SOURCE SCRIPT

2 Length Bollinger Bands

已更新
This indicator is a two length Bollinger Band implementation. It uses the Simple Moving Average, and adjusts to the period you are looking at: e.g. if you are looking at the day chart, periods are in days. If you are looking at the 5 minute chart, periods are within 5 minute increments.

The foregrounded set of bands is based on the 20 length SMA. So, in the case of the day chart, the successive bands from the middle are 1, 2, 2.5, and 3 standard deviations from the midline (which is a dotted orange line). The upper 2.5 and 3 stddev band is orange and red respectively. When the price gets up into these regions it could indicate a potential sell or short opportunity. The lower 2.5 and 3 stddev bands are colored with lime and green,when the price goes into these regions it indicates a potential buy opportunity.

The backgrounded set of bands is based on the 50 length SMA. So, in the case of the day chart, the successive bands from the middle are 1, 2, 2.5, and 3 standard deviations from the midline (which is a dotted purple line). It is intentionally more transparent so as to be seen as a slower background trend, so that the foreground bands (based on the 20 length SMA) can be interpreted within a developing context based on consideration of the slower period.

There are many other things to consider with Bollinger Bands, such as the 'squeeze' when the bands get narrow, which is often followed by a 'squeeze' up or down. It is best to consider BBs alongside other indicators (leading & lagging) and with consideration of volume in order to confirm or invalidate your thesis before making a trade.
版本注释
update to version 5
Bollinger Bands (BB)

开源脚本

本着真正的TradingView精神,此脚本的作者已将其开源,以便交易者可以理解和验证它。向作者致敬!您可以免费使用它,但在出版物中重复使用此代码受网站规则约束。 您可以收藏它以在图表上使用。

想在图表上使用此脚本?

免责声明