Coding help - page 41

 

Hi mladen,

Do you know why an EA would work exactly as it should on one timeframe and than not on another? For instance, MACD cross doesnt work properly, lot calculation doesnt appear correct, develops OrderSend and OrderModify errors 130, donchian channels not quite right. Its completely all over the place...

Than I change the timeframe back and its OK. I change the timeframe by changing the external variables in the actual code, say from TimingChart = 60;, to TimingChart = 240;

 

...

It can be only a problem somewhere in the code

Using "other time frames" is a regular procedure in EAs and indicators and should not cause any problems at all

crsnape@btinternet.com:
Hi mladen,

Do you know why an EA would work exactly as it should on one timeframe and than not on another? For instance, MACD cross doesnt work properly, lot calculation doesnt appear correct, develops OrderSend and OrderModify errors 130, donchian channels not quite right. Its completely all over the place...

Than I change the timeframe back and its OK. I change the timeframe by changing the external variables in the actual code, say from TimingChart = 60;, to TimingChart = 240;
 

Hello.

When I click on expert properties, I have the values there which is fine, but also start, step and stop. I realise these are optimizers, but my optimization box is unchecked on strategy tester and yet the start column has values- When I try to change the start values to zero, it ends up automatically calculating figures for step and stop. Why is this? I just want figures inserted into the value column. I dont want to optimize. Does it matter that these boxes get filled?

Also if I want to change the value of some external variables, how do I change them? Do I change them manually in my code, do I change them through expert properties, or do I right click on the expert advisor and go to properties and change the inputs from there? Because in this dialogue box it does not contain the start, stop and step columns. Or do I do all 3?

Thanks.

 

...

Here is a link to a thread that might help you in backtesting and optimizing : https://www.mql5.com/en/forum/general

I think that answers to a lot of things bothering you can be found on that thread

crsnape@btinternet.com:
Hello.

When I click on expert properties, I have the values there which is fine, but also start, step and stop. I realise these are optimizers, but my optimization box is unchecked on strategy tester and yet the start column has values- When I try to change the start values to zero, it ends up automatically calculating figures for step and stop. Why is this? I just want figures inserted into the value column. I dont want to optimize. Does it matter that these boxes get filled?

Also if I want to change the value of some external variables, how do I change them? Do I change them manually in my code, do I change them through expert properties, or do I right click on the expert advisor and go to properties and change the inputs from there? Because in this dialogue box it does not contain the start, stop and step columns. Or do I do all 3?

Thanks.
 

Hi Mladen,

Can you help me with this code?

The indicator I want to make is AvLife2, and the website is:

visualchart.com/esxx/ayuda_F1/Indicators/Medias/ML2.htm

My code is in attachment, but don't work.

avlife2_1.mq4

Files:
avlife2.mq4  3 kb
avlife2_1.mq4  3 kb
 
Potato7:
Hi Mladen,

Can you help me with this code?

The indicator I want to make is AvLife2, and the website is:

visualchart.com/esxx/ayuda_F1/Indicators/Medias/ML2.htm

My code is in attachment, but don't work.

avlife2_1.mq4

Anyone can Help me with this?

 

Hi

Can anyone enlighten me on how to make two EA's talk to or pass data to each other ? The two EA's are on two different MT4 platforms on one PC.

Thanks

pooh

 

....

Trying to refresh my Spanish

Will see what can be done

Potato7:
Hi Mladen,

Can you help me with this code?

The indicator I want to make is AvLife2, and the website is:

visualchart.com/esxx/ayuda_F1/Indicators/Medias/ML2.htm

My code is in attachment, but don't work.

avlife2_1.mq4
 

...

Potato7

It seams that there are some mistakes in the formula on that site

If in the following 2 formulas we leave the *(p-1) as is, it soon reaches the "infinity" in metatrader and that s why it is not showing anything.

But since that formula looks very much like smoothed moving average (not the same, but looks like) if some corrections are made, here is what is the result (the result looks very much like the picture on the site that you posted the link to, so I am just guessing that this should be it)

PS: made 2 versions (they use the "on chart version" and you started the "separate window" version) so these are the on chart and separate window versions

Potato7:
Hi Mladen,

Can you help me with this code?

The indicator I want to make is AvLife2, and the website is:

visualchart.com/esxx/ayuda_F1/Indicators/Medias/ML2.htm

My code is in attachment, but don't work.

avlife2_1.mq4
Files:
formula_1.gif  3 kb
formula_2.gif  3 kb
afl.gif  34 kb
avlife2_2.mq4  2 kb
 

mladen

you are the best!!!

Thank you very much !!!

Reason: