OPEN-SOURCE SCRIPT

Greedy DCA

Updated
█ OVERVIEW

Detect price crashes in volatile conditions. This is an indicator for a greedy dollar cost average (DCA) strategy. That is, for people who want to repeatedly buy an asset over time when its price is crashing.

█ CONCEPTS
  • Price crashes are indicated if the price falls below one or more of the 4 lower Bollinger Bands which are calculated with increasing multipliers for the standard deviation.
  • In these conditions, the price is far below the average. Therefore they are considered good buying opportunities.
  • No buy signals are emitted if the Bollinger Bands are tight, i.e. if the bandwidth (upper -lower band) is below the value of the moving average multiplied with a threshold factor. This ensures that signals are only emitted if the conditions are highly volatile.
  • The Bollinger Bands are calculated based on the daily candles, irrespective the chart time frame. This allows to check the strategy on lower time frames

Release Notes
█ CHANGELOG

  • Condition if bands are wide no longer depends of the number of standard deviations used to calculate the main Bollinger Bands.
  • Adjusted some default values for the number of standard deviations.
  • Skipped signals are now plotted in red.
Release Notes
plot the moving average calculated from the daily time frame, instead of the chart time frame
Bands and ChannelsbollingerbandstrategyBollinger Bands Width (BBW)btcusdbuyDCAmulti-timeframemultitimeframeVolatility

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 publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer