Discussion of article "Create Your Own Trading Robot in 6 Steps!" - page 3

 
danielalmaty:

Expert Advisor settings are like this

We meant testing settings, not input parameters of the Expert Advis or.

In addition to the settings, please give the demo account number and investment password to it.

 

Sorry, I'm a complete dummy on all these terms..... for now :)

Expert: ssssa.ex5 EURUSD H1

Date: Last Year

Execution: Normal Every tick

Deposit: 10000 USD 1:100

Optimisation: Fast Generic Based Algorithm Balance Max

(last time tried without optimisation )

Forward: NO

Everything is marked in the inputs as in the instructions

Login: 20354

Investor : xehan2y (read only password)

 

Hello!

1) I was trying to understand this line of code

MA_Cross::MA_Cross(void) : m_period_fast(13),          // default fast period MA=13
                           m_method_fast(MODE_SMA),    // default simple fast average averaging method
                           m_period_slow(21),          // default period slow MA=21 

I consider it useful to provide a link to the reference book:

MQL5 Reference Guide / Language Basics / Data Types / Structures and Classes

namely the example //--- constructor with the initialisation list CPerson(string surname,string name): m_second_name(surname), m_first_name(name) {};

2) By the way, whoever is writing the help, notice in this section of the help:

Looks like a class declaration error: in the

Classes Classes have a number of differences from structures....

Example:

struct trade_settings
{

 
danielalmaty:

Login: 20354

Investor : xehan2y (read only password)

I connected to this account and started testing(not optimisation!). The automatic loading of history started and trades started. I have a suspicion that you are confusing optimisation and testing. When optimising you will not see trades!


 
bivmail:

Hello!

1) I was trying to understand this line of code

I consider it useful to provide a link to the reference book:

MQL5 Reference Guide / Language Basics / Data Types / Structures and Classes

namely the example //--- constructor with the initialisation list CPerson(string surname,string name): m_second_name(surname), m_first_name(name) {};


Thanks , a suggestion has been added to the article:

Initialisation of class members here is done using an initialisation list.

 
bivmail:

2) By the way, whoever is writing the help, pay attention in this section of the help:

Looks like a class declaration error: in the

Classes Classes have a number of differences from structures....

Example:

struct trade_settings
{

Do you mean this place?


 
danielalmaty:

This is what I'm getting.

Very strange, the number of bars, ticks and modelling quality are the same. Do you have UAC enabled? What folder is the terminal installed in?


Что такое контроль учетных записей? - Справка Microsoft Windows
Что такое контроль учетных записей? - Справка Microsoft Windows
  • support.microsoft.com
Контроль учетных записей - это компонент Windows, предназначенный для управления компьютером и уведомления о внесении программами изменений, требующих прав администратора. Контроль учетных записей основан на применении различных уровней разрешений для учетной записи пользователя. При выполнении задач, доступных обычному пользователю, таких как...
 
I just initialised the eXpert from the article again and it worked, with the same result as yours. so the problem was in my code from what I did.

But I tried to optimise with the same expert and it gives the error TESTED WITH ERROR "Cannot initialise Expert"

can you please check again from my account what it will write to you if you optimise?

 
danielalmaty:

can you please check from my account again what it will write to you if you optimise?

Just restart the terminal and try again. Perhaps the tester has "caught on" to an old version of the compiled Expert Advisor.
 
Rosh 2012.03.22 11:08 #
bivmail:

2) By the way, whoever is writing the help, pay attention in this section of the help:

looks like a class declaration error: in the section

Classes Classes have a number of differences from structures....

Example:

struct trade_settings
{

Do you mean this place?

Yes, I've now worked out that this is a generic example for classes and struct.

The logic worked on the basis of priorities according to the scheme

Structure - Example, Class - Example,

and then regardless of structure / class we have a general rule:

...if a constructor is explicitly defined, it is impossible to initialise a variable of a structure or class type using an initialising sequence.

There is an example missing here for a class.... ok. I'll be more flexible :-)

2) Why is the comment so strikingly different (imho, the meaning in the fifth is similar to the fourth, namely, we call a method of the base class, what are additional filters)?

раздел 4 

   //--- call the method of the base class

   if(!CExpertSignal::ValidationSettings())  return(false);

раздел 5

//--- initialisation of indicators and time series in additional filters

   if(!CExpertSignal::InitIndicators(indicators)) return(false);