Type/to search

Bollinger Bands Breakout Strategy

Cryptocurrency
Created: 2023-09-19 16:06:56
Last modified: 3 years ago
1
Follow
1781
Followers

Overview

This strategy is based on the Bollinger Bands indicator. It goes long when the price breaks above the lower band and closes the position when the price touches the upper band. The strategy utilizes the containment principle of Bollinger Bands to track abnormal price breakouts for buying low and selling high.

Strategy Principle

  1. Calculate the middle band SMA as the simple moving average of recent closing prices.

  2. Calculate the standard deviation StdDev to reflect the price fluctuation range.

  3. Add the upper offset of standard deviation to the middle band SMA to get the upper band.

  4. Subtract the lower offset of standard deviation from the middle band SMA to get the lower band.

  5. Go long when the closing price breaks above the lower band from bottom up.

  6. Close the position when the price touches the upper band, as the price is considered abnormal.

Advantage Analysis

The biggest advantage of this strategy is utilizing the statistical properties of Bollinger Bands to effectively track abnormal market fluctuations and capture trends. Compared to regular moving average strategies, Bollinger Bands strategies have more advantages:

  1. Bollinger Bands upper and lower bands can automatically adapt to market volatility.

  2. Breakout signals are more reliable for entry.

  3. Reversion to mean is reasonable for taking profit.

  4. Huge parameter tuning space for adjusting to different markets.

  5. Can capture mid-to-long term trends and also be used for short term.

Risk Analysis

The potential risks of this strategy are mainly:

  1. Poor performance of Bollinger Bands in range-bound markets, avoid wrong entries.

  2. Breakout signals may be false breakouts, need prudent judgements.

  3. Profit taking position is too idealized, can be optimized to actual price action.

  4. Improper parameter settings may lead to over-trading or over-conservatism.

  5. Backtest period needs to be long enough to avoid curve fitting.

Corresponding risk management measures:

  1. Add trading volume indicators to filter signals.

  2. Optimize parameters and test data from different markets.

  3. Add trailing stop loss, stagger take profit levels.

  4. Assess signal divergences, avoid chasing highs and selling lows.

Optimization Directions

The strategy can be optimized in the following aspects:

  1. Try different combinations of Bollinger Bands parameters to find the optimal.

  2. Add MA, MACD etc to filter breakout signals.

  3. Apply machine learning algorithms to optimize Bollinger parameters.

  4. Assess the strength of breakouts and adjust position sizing.

  5. Backtest longer periods to test stability.

  6. Add stop loss mechanisms to control risk.

Summary

In summary, the Bollinger Bands strategy is an overall reliable trend following strategy. It can effectively capture abnormal price fluctuations. But we should also note its deviation from actual price and constantly optimize the parameters. If used for live trading, strict risk management is a must to control loss per trade.

Source
Pine
/*backtest
start: 2023-09-11 00:00:00
end: 2023-09-12 04:00:00
period: 10m
basePeriod: 1m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

//@version=4

strategy(title="BB training No Repainting (OTS Mode)", overlay=true)
Strategy parameters
Strategy parameters
Backtest Start Year
Backtest Start Month
Backtest Start Day
Backtest Stop Year
Backtest Stop Month
Backtest Stop Day
Color Background?
SMA Length
StdDev Length
Upper Band Offset
Lower Band Offset
Comment
All comments (0)
No data
No data
  • 1
iPhone Download
Forums
PINE Language
© 2015 - ∞ INVENTOR PTE LTD (SG)