Discussion of article "Simple Trading Systems Using Semaphore Indicators"

 

New article Simple Trading Systems Using Semaphore Indicators is published:

If we thoroughly examine any complex trading system, we will see that it is based on a set of simple trading signals. Therefore, there is no need for novice developers to start writing complex algorithms immediately. This article provides an example of a trading system that uses semaphore indicators to perform deals.

Fig.4. Trading signal for performing a deal using Heiken Ashi Smoothed semaphore trend indicator


Author: Nikolay Kositsin

 

I compiled some Signals and restart, like "Candles_SmoothedSignal.mqh" (..MQL5\Include\Expert\MySignals\Candles_SmoothedSignal.mqh), but MetaEditor can not see it to make an Expert Advisor in the Wizard.

How can I solved it?


 

Thanks for this most excellent and thorough explanation ...!


daveM

 

Forum on trading, automated trading systems and testing trading strategies

Discussion of the article "Simple trading systems using semaphore indicators"

Vladimir Karputov , 2019.10.30 08:50

The order is important:

 // wizard description start
//+----------------------------------------------------------------------+
//| Description of the class                                             |
//| Title=The signals based on ASCtrend indicator                        |
//| Type=SignalAdvanced                                                  |
//| Name=ASCtrend                                                        |
//| Class=CASCtrendSignal                                                |
//| Page=                                                                |
//| Parameter=BuyPosOpen,bool,true,Permission to buy                     |
//| Parameter=SellPosOpen,bool,true,Permission to sell                   |
//| Parameter=BuyPosClose,bool,true,Permission to exit a long position   |
//| Parameter=SellPosClose,bool,true,Permission to exit a short position |
//| Parameter=Ind_Timeframe,ENUM_TIMEFRAMES,PERIOD_H4,Timeframe          |
//| Parameter=RISK,int,4,Risk level                                      |
//| Parameter=SignalBar,uint,1,Bar index for entry signal                |
//+----------------------------------------------------------------------+
// wizard description end 

but not

 //--- wizard description start
//--- wizard description end 

and between start and end only the service block - no variables and macro substitutions.


This is the beginning the module should have:

 //+------------------------------------------------------------------+
//|                                               ASCtrendSignal.mqh |
//|                             Copyright © 2011,   Nikolay Kositsin |
//|                              Khabarovsk,   farria@mail.redcom.ru |
//+------------------------------------------------------------------+
#property  copyright "Copyright © 2011, Nikolay Kositsin"
#property  link        "farria@mail.redcom.ru"
//+------------------------------------------------------------------+
//| Included files                                                   |
//+------------------------------------------------------------------+
//#property tester_indicator "ASCtrend.ex5"
#include  <Expert\ExpertSignal.mqh>
// wizard description start
//+----------------------------------------------------------------------+
//| Description of the class                                             |
//| Title=The signals based on ASCtrend indicator                        |
//| Type=SignalAdvanced                                                  |
//| Name=ASCtrend                                                        |
//| Class=CASCtrendSignal                                                |
//| Page=                                                                |
//| Parameter=BuyPosOpen,bool,true,Permission to buy                     |
//| Parameter=SellPosOpen,bool,true,Permission to sell                   |
//| Parameter=BuyPosClose,bool,true,Permission to exit a long position   |
//| Parameter=SellPosClose,bool,true,Permission to exit a short position |
//| Parameter=Ind_Timeframe,ENUM_TIMEFRAMES,PERIOD_H4,Timeframe          |
//| Parameter=RISK,int,4,Risk level                                      |
//| Parameter=SignalBar,uint,1,Bar index for entry signal                |
//+----------------------------------------------------------------------+
// wizard description end
//+------------------------------------------------------------------+
//|  Declaration of constants                                        |
//+------------------------------------------------------------------+
#define  OPEN_LONG     80    // The constant for returning the buy command to the Expert Advisor
#define  OPEN_SHORT     80    // The constant for returning the sell command to the Expert Advisor
#define  CLOSE_LONG     40    // The constant for returning the command to close a long position to the Expert Advisor
#define  CLOSE_SHORT   40    // The constant for returning the command to close a short position to the Expert Advisor
#define  REVERSE_LONG   100 // The constant for returning the command to reverse a long position to the Expert Advisor
#define  REVERSE_SHORT 100 // The constant for returning the command to reverse a short position to the Expert Advisor
#define  NO_SIGNAL       0    // The constant for returning the absence of a signal to the Expert Advisor
//+----------------------------------------------------------------------+
//| CASCtrendSignal class.                                               |
//| Purpose: Class of generator of trade signals based on                |
//| ASCtrend indicator values http://www.mql5.com/ru/code/491/.          |
//| Is derived from the CExpertSignal class.                             |
//+----------------------------------------------------------------------+
class CASCtrendSignal : public CExpertSignal
  {

restart the MetaEditor after making changes