Skip to content
All library documents

Darvas Box Breakouts with Trend Signals and Risk Controls

Article Strategy library · Author: ChaoZhang

Summary

The document explains a Darvas Box approach that defines upper and lower price boundaries from recent highs and lows. Its code generates a long entry when the close crosses above the box top and closes that position when price crosses below the box bottom. The box length is configurable, with a default of five periods. The accompanying strategy description discusses using moving averages, MACD, and RSI to confirm signals, but these indicators do not appear in the supplied code; the implementation relies on the box boundaries alone.

The document identifies false breakouts in ranging markets, delayed box formation, sensitivity to the length setting, and the absence of a defined profit-taking rule as limitations. It suggests possible additions such as volume confirmation, volatility-aware sizing, trailing or ATR stops, and multi-timeframe filters. Published settings specify a BTC/USDT Binance futures backtest using daily bars and a one-hour base period across dates from 2023 to 2024, but no performance statistics are given. The described configuration uses equity-based order sizing, so the risk discussion should not be taken as evidence that losses are capped.

Key ideas

  • The code constructs a price box from recent highs and lows and enters long on a close above its top.
  • A close below the box bottom closes the long position; the code does not open a short.
  • The written discussion proposes indicator confirmations that are absent from the supplied implementation.
  • The document identifies false breakouts, parameter sensitivity, and missing profit-taking rules as limitations.
  • Backtest settings are provided, but no performance results are reported.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.