You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I will get rid of the Print as suggested.
Any other advice to solve my problem?
I am attaching a document that shows how different the same EA performs under different MT4 demo terminals from the same broker.
You said "On another MT4 terminal I get 7 instead of only one transaction!!" what is important from the point of view of the way you have coded your EA is how many orders you have open at any one time . . . . it looks like you have no more than 4 and this is consistent with the way you have written your code, so there is no issue here, your code is doing what you coded it to do . . . why ? because you wrote this . . .
MaxTrans is 3, so if you have 3 open Buy orders that is equal to MaxTrans so it's OK to open another one, when you have 4 that is greater than MaxTrans so another Buy order is not opened.
Maybe it is something to do with your CCIReal variable, it is a CCI value for bar 0 so it is likely to be different for each tick during the formation of bar 0, using PRICE_CLOSE just means that you are using Close[0] value for Bar 0 which is the same as Bid.
Do you think it will solve the problem if I rather use shift=1 in my CCIReal variable?
You said "On another MT4 terminal I get 7 instead of only one transaction!!" what is important from the point of view of the way you have coded your EA is how many orders you have open at any one time . . . . it looks like you have no more than 4 and this is consistent with the way you have written your code, so there is no issue here, your code is doing what you coded it to do . . . why ? because you wrote this . . .
MaxTrans is 3, so if you have 3 open Buy orders that is equal to MaxTrans so it's OK to open another one, when you have 4 that is greater than MaxTrans so another Buy order is not opened.
I understand why up to four transactions can be opened at the same time, because that is the way I wrote the code.
But what I CANNOT understand is why I get such totally different results from two MT4 demo terminals from the same broker, same time period and same EA??
Would LOVE to know what results you will get when you run this EA for the same period on your terminal. (period 1 Nov 2012 - 9 Nov 2012)
I understand why up to four transactions can be opened at the same time, because that is the way I wrote the code.
But what I CANNOT understand is why I get such totally different results from two MT4 demo terminals from the same broker, same time period and same EA??
Would LOVE to know what results you will get when you run this EA for the same period on your terminal. (period 1 Nov 2012 - 9 Nov 2012)
I don't know if I have M1 and above data for 1st - 9th Nov 2012, which symbol ?
Do you think it will solve the problem if I rather use shift=1 in my CCIReal variable?
On the test runs I did I got significantly different results until I disconnected from my Broker. When I disconnected from my Broker I got slightly different results, this should not happen . . . I don't know why it is happening, it needs a detailed investigation.
I don't know if I have M1 and above data for 1st - 9th Nov 2012, which symbol ?
The symbol is EURUSD 1 Hour data.
The symbol is EURUSD 1 Hour data.
I don't have M1 data for that date range, I don't use my Brokers data for Strategy Tester work as it's likely to have holes in it. I do have M5 data though . . . lets see what happens . . .
I don't have M1 data for that date range, I don't use my Brokers data for Strategy Tester work as it's likely to have holes in it. I do have M5 data though . . . lets see what happens . . .
Thanks for the trouble! Highly appreciated!
Your results agree with my one MT4 terminal, but differs of course from the other one greatly. I suspect your data is tick data that was downloaded from a reliable source?
So can I assume that backtests made with data from a broker and that from reliable tick data could TOTALLY differ from each other? Even if the EA is not a scalper and uses an Hour timeframe and StopLoss of 80 and Profit Take of 230?
By the way, I get far more reliable results after I changed CCI from shift=0 to shift=1. THANKS for that hint!!!!
(Phi.nuts has been VERY quiet! I was hoping he could put more light on the possible problems than just a Print statement in a less acceptable place!)
Thanks for the trouble! Highly appreciated!
Your results agree with my one MT4 terminal, but differs of course from the other one greatly. I suspect your data is tick data that was downloaded from a reliable source?
So can I assume that backtests made with data from a broker and that from reliable tick data could TOTALLY differ from each other? Even if the EA is not a scalper and uses an Hour timeframe and StopLoss of 80 and Profit Take of 230?
By the way, I get far more reliable results after I changed CCI from shift=0 to shift=1. THANKS for that hint!!!!
Yep, that doesn't surprise me at all. :-)
By the way, have you had a play with the Debugging stuff I added to your code ?