DCA
đ Standard Deviation DCA Strategy
Automated position building using statistical price bands
A smart accumulation algorithm that executes buy/sell orders when price deviates significantly from its mean, with flexible order sizing and LIFO profit-taking options.
âď¸ Core Parameters
Amount
5000
Target token volume
Order_size_min
50
Base order size (in tokens)
Price_Low
2
Lower price boundary
Price_High
4
Upper price boundary
Period
1d
Order triggering frequency
Window_Size
21
Candles for mean/std calculation
Buy_Threshold
3
Buy when price < (mean - 3Ď)
Sell_Threshold
2
Sell when price > (mean + 2Ď)
đ Order Sizing Modes
1. Classic
Fixed-size orders:
Order_size_min
tokens per trade
2. Martingale
Order size increases exponentially from
Price_High
toPrice_Low
3. Logarithmic
Calculated per:
Where:
S
= Order_size_minM
= Multiplier (e.g., 1.05)n
= Trade count
đ Example: Buying TON with SD-DCA
Setup:
Mean price: 3.00,Ď=3.00,Ď=0.20
Buy trigger: 3.00â(3Ă3.00â(3Ă0.20) = $2.40
Log mode: M=1.05, S=50 TON
Execution:
Trade #1 at $2.40:
Size = 50 Ă (1 + 1.05Ăln(1)) = 50 TON
Trade #5 at $2.20:
Size = 50 Ă (1 + 1.05Ăln(5)) = 131 TON
LIFO Selling:
If price rebounds to $2.80 (mean + 2Ď):
Sells most recent buy first
đ Key Features
â Statistical edge - Buys at statistically "low" prices â Flexible scaling - Choose risk profile via order sizing â Auto-profit taking - LIFO selling locks gains
đĄ Risk Controls
â Price boundaries prevent extreme executions â Configurable Ď thresholds adjust sensitivity â Real-time PnL tracking
đ Performance Tracking
Realized PnL per closed position
Net average entry price
Missed signal diagnostics
đĽ Ideal For:
Accumulating during market dips
Mean-reversion strategies
Last updated