How to Use Dollar Cost Averaging (DCA) in Spot Trading Strategy
Dollar Cost Averaging (DCA) is an investment strategy where you divide the total amount to be invested across periodic purchases of a target asset. The goal is to reduce the impact of volatility on the overall purchase; purchases occur regardless of the asset's price and at regular intervals.
Dollar Cost Averaging (DCA), also referred to as Double Up (DU) within Gunbot, is a feature to automatically average down assets, bringing down the average cost per unit when prices drop after a regular buy order.
By reducing the average price per unit, the price required to exit the trade profitably also decreases. However, the inherent risk of averaging down is investing more in assets that have already declined in price. Use this feature carefully.
Use the DU guestimator sheet to simulate your DCA settings.
Feel free to make a copy of the file. Thanks Trashdog01!
How DCA Works​
Below is an example of using Dollar Cost Averaging. The relevant settings used in this example would be:
DU_METHOD
is set toHIGHBB
. With this method, each DCA buy is triggered when the upper Bollinger Band crosses below the last buy price.DOUBLE_UP_CAP
is set to 1. Each DCA buy uses quote currency equivalent to the current holdings.DU_CAP_COUNT
is set to 2. A maximum of two DCA buys are allowed.DU_BUYDOWN
is set to 1. This is the minimum required price percentage difference for a DCA buy compared to the previous order's buy price.
Note that this example is kept simple intentionally; the amounts do not reflect real trades.
Using the example above, this is an overview of the buy orders made—notice how the average price per unit moves down after each DCA buy:
Units | Price per unit | Invested (cumulative) | Avg Price per Unit | |
---|---|---|---|---|
Buy | 100 | 12.500 | 1,250,000 | 12,500 |
DCA Buy 1 | 100 | 10.800 | 2,330,000 | 11,650 |
DCA Buy 2 | 200 | 8.090 | 3,948,000 | 9,870 |
The resulting sell order would have profitably sold all available units at a much lower price than the initial buy order:
Units | Price per unit | Proceeds | |
---|---|---|---|
Sell | 400 | 10.000 | 4,000,000 |
Configurable options for averaging down are:
- Buydown (
DU_BUYDOWN
): The minimum price percentage difference required between the last buy and the next DCA buy. Regardless of the chosen DCA method, this buydown percentage must be met for a DCA buy to occur. - DCA Method (
DU_METHOD
): Options include HIGHBB (as shown previously, where buys trigger if the upper Bollinger Band crosses below the last buy price), RSI (DCA buys occur only within a configurable RSI range), or a numerical value (defining a percentage price drop from the last purchase price). - Ratio (
DOUBLE_UP_CAP
): Defines the amount of quote currency used for each DCA buy, relative to existing holdings. - Frequency (
DU_CAP_COUNT
): The maximum number of DCA buy orders allowed. - Trailing: DCA buy orders can optionally use trailing functionality.
Dollar Cost Averaging is a feature that allows you to invest significant amounts of your base currency. It's important to be cautious when setting the ratio and frequency, and to ensure that you have sufficient available funds.
DCA Settings​
Label | Config Parameter | Default Value | Detailed Description |
---|---|---|---|
DCA enabled | DOUBLE_UP | false | Enables the Dollar Cost Averaging (DCA) feature, a strategy used to reduce the average buying price of a cryptocurrency by purchasing additional units at lower prices. |
DCA cap | DOUBLE_UP_CAP | 1 | Sets the ratio of quote currency for each DCA order relative to your existing holdings. This determines the scale of your DCA buys. For example, a value of 1 means each DCA order uses quote currency equal to your current holdings, effectively doubling the invested amount in that asset to lower the average cost. Set this high enough to impact your average price significantly, but ensure it doesn't exceed your available balance. |
DCA cap count | DU_CAP_COUNT | 0 | Limits the maximum number of DCA orders that can be executed. This parameter helps control the extent of your DCA strategy and manage risk by capping the total number of times you can average down on a declining asset. |
DCA buydown | DU_BUYDOWN | 2 | Specifies the minimum percentage price drop from the last purchase required before placing another DCA order. A lower percentage can trigger more frequent DCA buys, potentially reducing the average cost faster, but risks consuming more capital if the asset's price continues to fall. |
DCA method | DU_METHOD | HIGHBB | Selects the method to trigger DCA orders. Options: HIGHBB (orders placed if the upper Bollinger Band drops below the last purchase price), RSI (orders triggered by a specific RSI level), or a numerical value (orders placed based on a set percentage drop from the last purchase price). This allows tailoring DCA triggers to market conditions or risk preferences. |
DCA RSI buy | RSI_DU_BUY | 30 | Specifies the RSI threshold for initiating a DCA buy when DU_METHOD is RSI. An RSI value below this threshold suggests an oversold condition, potentially an advantageous point for averaging down.This automates buying at perceived low points based on RSI, useful in volatile markets. |
Overview of Effects on Different Order Types​
Config Parameter | Affected Order Types | Not Affected Order Types |
---|---|---|
DOUBLE_UP | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
DU Method | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
Double Up Cap | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
DU Cap Count | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
DU Buydown | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
RSI DU Buy | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
Trail Me DU | DCA buy | Strategy buy, Strategy sell, Close, RT sell, Stop limit, RT buyback, RT buy |
Trail Me Buy Range | Strategy buy, RT Buy, DCA buy | Strategy sell, Close, Stop limit, RT sell, RT buyback |