Bollinger Bands are envelopes which surround the price bars on a chart. Bollinger Bands are plotted two standard deviations away from a simple short-term moving average. This is the primary difference between Bollinger Bands and envelopes. Envelopes are plotted a fixed percentage above and below a moving average. Because standard deviation is a measure of volatility, the Bollinger Bands adjust themselves to the market conditions. They widen during volatile market periods and contract during less volatile periods. Bollinger Bands become moving standard deviation bands. Bollinger Bands are displayed with a third line. This is the simple (short-term) moving average line. The time period for this moving average can vary. The default for short-term moving average in AmiBroker is 15 days.
An important thing to keep in mind is that Bollinger Bands do not generate buy and sell signals alone. They should be used with another indicator. RSI, for example, is quite good choice as a companion for Bollinger bands. When price touches one of the bands, it could indicate one of two things. It could indicate a continuation of the trend; or it could indicate a reaction the other way. So Bollinger Bands used by themselves do not provide all of what technicians need to know. Then RSI, which is an excellent indicator with respect to overbought and oversold conditions, comes with help. Generally, when price touches the upper Bollinger Band, and RSI is below 70, we have an indication that the trend will continue. Conversely, when price touches the lower Bollinger Band, and RSI is above 30, we have an indication that the trend should continue. If we run into a situation where price touches the upper Bollinger Band and RSI is above 70 (possibly approaching 80) we have an indication that the trend may reverse itself and move downward. On the other hand, if price touches the lower Bollinger Band and RSI is below 30 (possibly approaching 20) we have an indication that the trend may reverse itself and move upward. Avoid the trap of using several different indicators all working off the same input data.
If you're using RSI with the Bollinger Bands, don't use MACD too. They both rely on the same inputs. You might consider using On Balance Volume OBV, or Money Flow Index (MFI). RSI, On Balance Volume, and Money Flow, rely on different inputs.