molanis.com/forum - Tools for MetaTrader : The place to ask about the best expert advisor builder, expert advisor downloads, and expert advisor programming

AFTER YOU REGISTER SEND US AN EMAIL TO ACTIVATE YOUR ACCOUNT - Before posting:-1- Please read the user guide -2- Try the examples -3- Search in the forum
It is currently Sat May 11, 2024 5:26 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 19 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Regarding optimization
PostPosted: Thu Sep 19, 2013 8:03 am 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
Hello Molanis,

When using custom indicator to create an EA, after that if I want to optimization the parameter of the indicator, may I know how to do that, I won't be able to add the indicators parameter to the Trading block(start), because how good of the EA is base on indicators parameter after we created from it, so that the optimization of the indicators parameter is very importance for us, kindly let me know how to optimization for it?

Thank you!


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Thu Sep 19, 2013 2:47 pm 
Offline

Joined: Tue Dec 22, 2009 12:22 am
Posts: 1761
When you import a custom indicator the import string that is added in the field in the TA icon looks like:
"indicator_name",parameter 1, parameter 2... etc
Import a custom indicator and pay attention to that string

To optimize those parameters you need to change them into variables. So define a variable i.e. period. After importing the custom indicator you will see something like"
"indicator_name",parameter 1, parameter 2
change it to
"indicator_name",period, parameter 2

Make sure you use the variable in a fake condition otherwise it will not be added to the mq4 code. This is just a workaround. There is no easier way to do it


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Fri Sep 20, 2013 7:55 am 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
Hello Molanis,

Thank you for your reply!

I was trying to follow your method and changed it, but it was an error. Could you kindly explain more in detail how to do it. Now I attached with an indicator and mol files.

Thank you!


Attachments:
SignalLine EA.mol [6.65 KiB]
Downloaded 477 times
SignalLine.mq4 [3.41 KiB]
Downloaded 456 times
Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Mon Sep 23, 2013 8:02 pm 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
Please help me to resolved the problems!

Thank you!


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Mon Sep 23, 2013 9:04 pm 
Offline

Joined: Tue Dec 22, 2009 12:22 am
Posts: 1761
No Problem. For this issue send us an email referring this post - also include email used during purchase. Thanks


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Tue Sep 24, 2013 7:04 am 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
I haven't purchase yet, may I know can I try it first before I buy it, could you help me to resolved the problem first? I want to know how good of your software.

Thank you!


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Wed Sep 25, 2013 10:18 am 
Offline

Joined: Tue Dec 22, 2009 12:22 am
Posts: 1761
Please follow the instructions I gave you before. Your strategy does not have any variable or a fake condition that uses it


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Wed Sep 25, 2013 9:20 pm 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
As I was mentioned before, I am not sure where is the parameters I need to be change them into variables. Could you let me know more in detail? I am quite confusing. Please take a look of the mol file I was attached.

Thank you!


Attachments:
SignalLine EA 1 .mol [6.7 KiB]
Downloaded 407 times
Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Fri Sep 27, 2013 3:15 pm 
Offline

Joined: Tue Dec 22, 2009 12:22 am
Posts: 1761
Let's work with a simple example. Imaging you want to optimize a moving average indicator. This simple ma indicator only has the ma period as the input so if you import the indicator in the TA icon you will see something like "ma",14 where 14 is the period
If you want to optimize the ma period you rewrite "ma",14 as "ma",myvariable
Then you define myvariable in the mtvar icon
Finally you create a fake TA+ - BUY condition that uses myvariable (this is required otherwise the variable will not be created and you will get an error)


Top
 Profile  
 
 Post subject: Re: Regarding optimization
PostPosted: Sat Sep 28, 2013 8:02 am 
Offline

Joined: Thu Aug 12, 2010 7:49 am
Posts: 81
Thank you for your reply.

I was following your instruction to do the setting, but I still facing the problems, when I want to create Expert Adviser for Metatrader 4, I have an error messages shown that "MQL compiler execution failed". I do not know what's wrong with it, need your advice, please find an attached error files.

Thank you!


Attachments:
Doc1.pdf [289.67 KiB]
Downloaded 519 times
SignalLine.mq4 [3.41 KiB]
Downloaded 406 times
SignalLine EA 1 .mol [7.38 KiB]
Downloaded 408 times
Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 19 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by Molanis © 2009