Catch breakouts by opening positions based on the previous day's range. Popularized by Larry Williams.
- Get previous day's high and low
- Set limit order based on previous day's range
- Close position at end of day
The following are results from a backtest from 2020-01-01
to 2020-12-31
with the below config. A simple buy & hold strategy is used as a benchmark.
{
"ticker": "ETH-PERP",
"k": 0.6,
"stoploss": 0.02,
"leverage": 1
}
Metric | |
---|---|
Trades | 113 |
Max Drawdown | -7.230% |
Return | 304.713% |
Benchmark Max Drawdown | -61.446% |
Benchmark Return | 471.245% |
The model underperforms the benchmark, however, the model is very successful in reducing downside exposure. Increasing the leverage to 2x or 3x will significantly outperform the benchmark while maintaining tolerable drawdowns in portfolio value.
Make sure to set secret
and key
in config.json
or pass as env vars.
See Makefile
> docker build breakout-trader .
> docker run -p 4000:4000 breakout-trader
Navigate to https://localhost:4000
for dashboard
The dashboard can be used to monitor your open orders and positions. The bot can also be disable and all positions and orders can be closed manually. Supports mobile view.
Dashhoard |
---|
![]() |
See the v2 branch for more configuration options like shorting and moving averages. This is the branch I am using and testing from but might not be ready for use and is subject to change. It also integrates with slack which I haven't made optional yet.