Jump to content


Photo

Building an EA for all as tutorial

tutorial building

  • Please log in to reply
14 replies to this topic

#1 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 27 February 2017 - 06:43 PM

Hello,

 

I'm not a programmer and I thought buying the EA Wizard would be much easier to build an EA with. But after some building practice I see you need to be a mql-Programmer to understand even EA Wizard.

So I come up with a question to you: Is it possible to build in this forum at least one EA step-by-step for better understanding for all non-programmers the EA Wizard?

 

I have already a strategy which is discribed here: https://www.mql5.com/en/articles/1734 

In this strategy there are code snippets. Actually I don't know how to integrate them. But more than this I want to understand and leran how am I building such an EA in EA Wizard. So that I can build other EAs in future.

The code snippets from the article are in the mq4.

 

Hopefully greetings from

Conmariin :)

 



#2 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 28 February 2017 - 08:12 PM

Hello,

 

have you tried our EA Wizard? Basically you do not need to be a programmer to make your EA. 

 

You can use Wizard for 14 days trial. You can get a SQ Pro trial license here http://www.strategyquant.com/trial that can be used for the EA Wizard too



#3 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 28 February 2017 - 08:35 PM

Hello,

 

have you tried our EA Wizard? Basically you do not need to be a programmer to make your EA. 

 

You can use Wizard for 14 days trial. You can get a SQ Pro trial license here http://www.strategyquant.com/trial that can be used for the EA Wizard too

 

Yes, I bought the EA Wizard already. And I tried to make some EAs with it. As I described above. And yes it is better to have programming practice or know how to build a profitable EA. Because you need to know the logic how an EA in mql works.

But that wasn't the point. My question was: Is it possible to build in this forum at least one EA step-by-step for better understanding for all non-programmers the EA Wizard?



#4 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 01 March 2017 - 10:37 PM

Hello,

 

so you mean you need a tutorial on using custom codes in Wizard or just using the built-in tools and functions?



#5 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 30 March 2017 - 09:38 PM

Hello,

 

so you mean you need a tutorial on using custom codes in Wizard or just using the built-in tools and functions?

I mean how to use custom codes. For example I have in this strategy two things I don't know how to realize:

 

1. There are several Variable Definitions like this one: double O1=NormalizeDouble(iOpen(Symbol(),PERIOD_M1,2),4);

Where and how do I declare this variable definition.

 

2. And there are several Conditions like this one: if(C1 >= O1 && L1 < O1 && ((O1-L1)>(C1-O1)) && C2 >= O2 && C2 >
H1 && L2 > L1)

Which is in fact 6 conditions.

 

How is the path to successfully integrate this code into EA Wizard?

Thank you!

 

Conmariin :)



#6 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 31 March 2017 - 08:51 AM

Okay, I think I know now how I can integrate the conditions from question 2. But I still clueless how I can realize the variable definitions in EA Wizard?

#7 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 31 March 2017 - 11:39 PM

Hello,

 

do you mean how to calculate a value and assign it to a variable for later use ....?



#8 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 01 April 2017 - 07:59 AM

Hm, I think not. It's about defining variable definitions.

Actually I can set variables in the strategy parameters. It's a kind of double, int, string and boolean. And I can say which value it should have.

But I have this variable definition double O1=NormalizeDouble(iOpen(Symbol(),PERIOD_M1,2),4); where O1 is the variable. So my question is, where can I define the rest on the right side of the = ?

 

The dirty solution is:

 

Define the "dummy" variables like this http://img4web.com/view/39FE5K

 

So I will be able to build the trading rules http://im g4web.com/view/FUA7XC

 

When the EA is ready and I have the code I will change the variable definitions in the Metatrader Editor manually.

 

This works but it would be nice to do it all in EAWizard. Especially when I want to make changes later.



#9 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 03 April 2017 - 06:50 PM

Hello,

 

you can just assign values to a variable as shown on screenshot attached

Attached Thumbnails

  • defineVar.jpg

Attached Files



#10 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 04 April 2017 - 08:20 PM

Ah! Thank you! :)

Much better!

 

But I opened the Metatrader Editor and it says something like in the attachment.

I looked into the code and there is a lot of code in it I didn't want to (Harami, Doji...)

It seems to interfere because my variable names are the same like this one in Harami, Doji...

How can I get rid of it. So that I can exclude errors from that?

Attached Thumbnails

  • Unbenannt.JPG


#11 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 04 April 2017 - 09:12 PM

Hello,

 

so you can define variable like Open1, Close1 then ...



#12 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 07 April 2017 - 10:57 AM

Okay, I renamed the variables. No errors anymore. :)

 

So the PriceAction is complete. I don't know how to integrate the S and R like in the article. So I ask, does anybody have an idea which indi or something else I can take instead of the S and R?

The PriceActionEA build so far is in the attachment.

 

Thank you! :)

 

 

Attached Files



#13 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 12 April 2017 - 04:51 PM

So I ask, does anybody have an idea which indi or something else I can take instead of the S and R?

 

You can use higher timeframe bars high / lows to define S and R levels, simple and could work



#14 Conmariin

Conmariin

    Member

  • Members
  • PipPip
  • 16 posts

Posted 14 April 2017 - 03:17 PM

aha. Okay. And position of the s and r are automatically set? Hm. I have to think about. At the moment I don't know how to start.



#15 tomas262

tomas262

    Advanced Member

  • Moderators
  • 2,076 posts

Posted 19 April 2017 - 06:42 PM

Hello,

 

you can create variables - support, resistance and if for example you trade M30 timeframe you can assign these variables values of H4 timeframe

 

resistance = High(H4)[1]

support = Low(H4)[1]

 

or similar






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users