How a Simple Candles Strategy Achieved a 90% Win Rate With 7-Year Automated Backtest

CodeTrading
9 Nov 202414:40

Summary

TLDRThis video showcases a simple trading strategy based on Larry Williams' 1999 pattern, which was backtested on EUR/USD and GBP/USD over 7 years. The strategy relies on engulfing candles to generate buy or sell signals and uses a 200-pip stop-loss. Despite a high win rate (87%), the returns remain modest due to quick trade closures. The strategy’s simplicity and consistent performance, with a relatively low drawdown, make it appealing for short-term traders, although those seeking larger profits may want to experiment with longer trade durations or different stop-loss settings.

Takeaways

  • 😀 The strategy tested in the video is a simple candlestick pattern originally published by Larry Williams in 1999.
  • 😀 The strategy showed an impressive 87% win rate after being backtested on EUR/USD and GBP/USD over seven years.
  • 😀 The pattern involves waiting for an 'external red candle' (bearish engulfing) to enter a long position and an 'external green candle' (bullish engulfing) to enter a short position.
  • 😀 Entry conditions require a close below the low of the previous candle for long trades and above the previous candle's high for short trades.
  • 😀 The strategy uses a 200-pip stop-loss for risk management, and trades are closed either when the stop-loss is hit or the trade becomes profitable by the next session.
  • 😀 The code implementation in Python reads CSV data, generates signals based on the strategy's rules, and allows backtesting on multiple assets.
  • 😀 The backtest results showed that while the win rate was high, the aggregated returns were not particularly impressive due to quick trade exits.
  • 😀 A separate optimization strategy involving adjustable stop-loss and take-profit percentages yielded an aggregated return of 181%, but this was not the focus of the video.
  • 😀 Despite high win rates (90% for EUR/USD), the actual returns were modest due to the strategy closing winning trades at the next session’s open.
  • 😀 The strategy's simplicity and low drawdown (max drawdown of -12%) make it appealing for traders looking for a straightforward and relatively safe approach.
  • 😀 The video encourages experimenting with the provided Python code to test the strategy, with potential modifications to suit individual preferences or market conditions.

Q & A

  • What is the core concept behind the strategy tested in the video?

    -The core concept is a simple pattern where a long position is taken when a red external candle engulfs the previous candle's high and low, and closes below the previous candle's low. For a short position, a green external candle is used, closing above the previous candle's high. The trade is exited either when the stop-loss (200 Pips) is hit or at the end of the next session if the trade is winning.

  • What were the backtest results for EUR/USD and GBP/USD?

    -The strategy showed a 90% win rate on EUR/USD and an 84.5% win rate on GBP/USD. The aggregated return for EUR/USD was 12%, while GBP/USD generated a return of 14%, totaling 26% across both pairs. The maximum drawdown was around 12%, with an average drawdown of 1.22%.

  • Why is the aggregated return not as high despite the high win rate?

    -The high win rate is due to the strategy closing winning trades quickly, often on the next day's open, which limits the profit potential. The 200 Pips stop-loss is relatively large compared to the modest reward achieved per trade, leading to limited returns despite frequent wins.

  • How does the strategy manage risk?

    -The strategy manages risk by using a 200 Pips stop-loss for each trade. Additionally, trades are closed either when the stop-loss is hit or when the trade becomes profitable by the next session's close. The approach limits the potential drawdown, with maximum and average drawdowns kept relatively low.

  • What role does optimization play in the strategy?

    -Optimization is applied to determine the best stop-loss and take-profit percentages for each asset. This improves the return by finding the most effective settings for each pair. However, the optimized strategy also showed impressive but modest returns, as the stop-loss is still larger than the take-profit potential.

  • What is the key difference between Strategy 1 and Strategy 2 in the video?

    -Strategy 1 involves optimizing stop-loss and take-profit percentages for each asset to maximize returns. In contrast, Strategy 2, which is explained in the video, uses a fixed stop-loss of 200 Pips without optimization. Strategy 2 achieves a high win rate but lower returns because it exits trades quickly without allowing for larger profit potential.

  • What does the code implementation do for this strategy?

    -The code implements functions to load and clean the data, detect trade signals based on the strategy's conditions, and manage trade execution with stop-loss calculations. It also plots signals on a candlestick chart, allowing users to visualize when trades were triggered during backtesting.

  • How are the trade signals generated in the code?

    -The trade signals are generated by evaluating four conditions: whether the current candle is bearish or bullish, whether it engulfs the previous candle's high and low, and whether it closes above or below the previous candle's high or low. If these conditions are met, the function generates a buy or sell signal, which is plotted on the chart.

  • What would happen if a trader used the strategy without optimization?

    -Without optimization, the strategy would still function with the default 200 Pips stop-loss and no take-profit. However, the return on investment may not be as high as with optimization, since the stop-loss might not be the most efficient for every asset, potentially leading to smaller profits per trade.

  • Why might this strategy work better on some assets compared to others?

    -The strategy's effectiveness can vary depending on the asset's price behavior and volatility. Some currency pairs may have more consistent price movements that align with the conditions of the strategy, while others may have more erratic movements, making it harder for the strategy to capture profit in the same way.

Outlines

plate

此内容仅限付费用户访问。 请升级后访问。

立即升级

Mindmap

plate

此内容仅限付费用户访问。 请升级后访问。

立即升级

Keywords

plate

此内容仅限付费用户访问。 请升级后访问。

立即升级

Highlights

plate

此内容仅限付费用户访问。 请升级后访问。

立即升级

Transcripts

plate

此内容仅限付费用户访问。 请升级后访问。

立即升级
Rate This

5.0 / 5 (0 votes)

相关标签
Candlestick StrategyBacktestingForex TradingPython TradingLarry WilliamsEUR/USDGBP/USDHigh Win RateTrading AlgorithmFinancial StrategyRisk Management
您是否需要英文摘要?