Creating a Powerful EA with MQL5 Wizard: Trading Signals from 3 Black Crows and 3 White Soldiers

Mike 2011.02.16 21:50 30 0 0
Attachments

If you're looking to take your trading game to the next level, the MQL5 Wizard is a fantastic tool for developing Expert Advisors (EAs) based on the Standard Library classes that come with the MetaTrader 5 platform. This handy feature allows you to quickly test your trading ideas by creating a custom trading signals class. For a detailed guide on setting this up, check out Creating Ready-Made Expert Advisors in MQL5 Wizard.

The concept is pretty straightforward: derive your trading signals class from CExpertSignal, and then override the LongCondition() and ShortCondition() methods with your own logic.

There's a great resource titled "Strategies of Best Traders" (in Russian) that discusses various trading strategies. For our purposes, we'll focus on reversal candlestick patterns confirmed by indicators like Stochastic, CCI, MFI, and RSI.

The best practice is to create a separate class derived from CExpertSignal for identifying candlestick patterns. To confirm trade signals generated by these patterns, you can implement a class derived from CCandlePattern and add the necessary confirmation features, such as oscillator checks.

In this post, we’ll explore signals based on the "3 Black Crows" and "3 White Soldiers" candlestick patterns, confirmed by the Stochastic indicator. The signal module is built upon the CCandlePattern class, showcasing a simple example of using candlestick patterns for trade signals.


1. Understanding the "3 Black Crows" and "3 White Soldiers" Patterns

1.1. 3 Black Crows

The "3 Black Crows" is a bearish candlestick pattern indicating a potential reversal of an uptrend. This pattern features three consecutive long-bodied candles closing lower than the previous day, with each session opening within the body of the preceding candle.

Figure 1. 3 Black Crows candlestick pattern

Figure 1. 3 Black Crows candlestick pattern

The recognition of this pattern is handled by the CheckPatternThreeBlackCrows method in the CCandlePattern class:

//+------------------------------------------------------------------+
//| Checks formation of                     
List
Comments 0