Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, 1 invisible), 1,395 guests, and 12 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19055 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 7 of 7 1 2 3 4 5 6 7
Re: Brokers incompatible with MT4 bridge? [Re: boatman] #458714
03/26/16 08:20
03/26/16 08:20
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
I guess this was becoming a large confusion.

I'm not sure what problems we're talking about. You originally reported MT4 outliers that were indeed confirmed and fixed. Then you got a bad looking chart due to Ichimoku starting at 0, which I suggested to fix by not plotting during lookback. Then you told me that this would still trigger wrong trades. That's where you lost me. Was this the original bug that was fixed, or is there still another problem?

Re: Brokers incompatible with MT4 bridge? [Re: jcl] #458715
03/26/16 10:34
03/26/16 10:34
Joined: Apr 2014
Posts: 482
Sydney, Australia
B
boatman Offline OP
Senior Member
boatman  Offline OP
Senior Member
B

Joined: Apr 2014
Posts: 482
Sydney, Australia
Originally Posted By: jcl
Was this the original bug that was fixed, or is there still another problem?


This is what I am trying to determine. I think this is the original bug that was fixed, since I can't seem to reproduce the error that I described in post #458662. But I'd like to be sure.

My understanding is that your explanation for the errors I described in post #458662 is:

Originally Posted By: jcl

The Ichimoku has no precautions against returning zero due to nonexisting data. This will be fixed in the next update, but inbetween you can simply solve it by plotting the Ichimoku only when the lookback period is over.


There's a very good chance that I'm missing something here, but I don't see how simply not plotting the indicator is a workaround for the incorrect values returned by the Ichimoku. My trading logic depends on these values, whether they are plotted or not. Could you perhaps provide some more detail that would help me understand?

Last edited by boatman; 03/26/16 10:34.
Re: Brokers incompatible with MT4 bridge? [Re: boatman] #458721
03/26/16 13:40
03/26/16 13:40
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
Certainly. Most indicators have a validity range. Look at the simple moving average, SMA(100). It is invalid between bars 0-98 and valid from bar 99 on. This is no bug and has nothing to do with wrong trades. It is just due to the definition of the indicator and the fact that data does not exist before bar 0.

What I suggested was simply not plotting invalid indicator values. I hope that you're not trading them anyway.

Re: Brokers incompatible with MT4 bridge? [Re: jcl] #458726
03/26/16 22:25
03/26/16 22:25
Joined: Apr 2014
Posts: 482
Sydney, Australia
B
boatman Offline OP
Senior Member
boatman  Offline OP
Senior Member
B

Joined: Apr 2014
Posts: 482
Sydney, Australia
Thanks, that explanation helped me understand how you are viewing my problem. Following that logic, the error that I posted could not possibly occur after the lookback period if it was related to the validity range of the indicator. Since it did occur after the lookback period, I have to conclude that the error had another source. I will continue running the script on the next trading session and see if it happens again.

Re: Brokers incompatible with MT4 bridge? [Re: boatman] #458755
03/29/16 09:30
03/29/16 09:30
Joined: Apr 2014
Posts: 482
Sydney, Australia
B
boatman Offline OP
Senior Member
boatman  Offline OP
Senior Member
B

Joined: Apr 2014
Posts: 482
Sydney, Australia
I have an update on the error I have been experiencing. There is still something not right, and I believe I have narrowed it down. Firstly, some context:

I have been testing a script that plots the indicators that control the trade logic, but which does not take any trades. The trade logic is commented out. It is the same script I sent to support with one minor alteration (details below). The script looks at two time frames (5-minute and 1-hour) and plots the Ichimoku senku spans from each time frame. I am now using TimeFrame = frameSync(60) to control the H1 indicators, rather than just TimeFrame = 60 in the original script sent to support.

I have been running the script on Katalon markets MT4 via the MT4 brdige V1.9. In parallel, I am running a copy of the script on an FXCM demo account via the API. I have printed out the indicator values from the 1-hour time frame into a log file.

The indicators from the 5-minute time frame look perfectly fine. The values closely match between the FXCM API and the MT4 bridge instances. The plots of these indicators match each other and the equivalent indicators plotted in the Katalon MT4 terminal.

The indicators from the 1-hour time frame are a different story. They almost match, but with some very obvious differences. Below I show plots from the FXCM API instance, the MT4 bridge instance and finally from the Katalon MT4 terminal. The former two show both the 5-minute indicators (orange) and price action and the 1-hour indicators (blue). The chart from the MT4 terminal shows the 1-hour indicators and price action only. The period of interest is between the two red vertical lines.

You can see that the MT4 bridge version doesn't quite match the FXCM API version and the MT4 terminal verion. It can't be explained by differences in the broker feed, since the MT4 terminal is the same broker being accessed via the MT4 bridge.

Curious that I can't see any errors on the 5-minute indicators, only in the 1-hour indicators. Does this give a clue as to the source of the error?

MT4 Bridge version:


FXCM API version:


MT4 terminal version:


I will upload the log files in a separate post.

Re: Brokers incompatible with MT4 bridge? [Re: boatman] #458756
03/29/16 09:36
03/29/16 09:36
Joined: Apr 2014
Posts: 482
Sydney, Australia
B
boatman Offline OP
Senior Member
boatman  Offline OP
Senior Member
B

Joined: Apr 2014
Posts: 482
Sydney, Australia
Is there a way to upload text files to the forum? I don't see the "File Manager" link that is referred to in the FAQ.

Re: Brokers incompatible with MT4 bridge? [Re: boatman] #458761
03/29/16 13:59
03/29/16 13:59
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
It was deactivated, but should be visible now. - We got your logs, but the difference between FXCM and MT4 is the server time. While the FXCM server time reflects the real time, the MT4 server time has only the time of the last price update. This leads to the time frame series being shifted at different times. For this reason we had already thought about removing the MT4 server time function altogether.

For a quick fix, can you replace TimeFrame = frameSync(12) just by TimeFrame = 12? Or is there a reason for trading exactly at hour boundaries?

Update: I've just looked in your script again. In fact we have a worse problem. I didn't notice it first, but I believe your H1 Ichimoku signals probably won't work at all - regardless of FXCM or MT4. I'll contact you by email about this and we'll work out a solution.

Re: Brokers incompatible with MT4 bridge? [Re: jcl] #458764
03/29/16 20:19
03/29/16 20:19
Joined: Apr 2014
Posts: 482
Sydney, Australia
B
boatman Offline OP
Senior Member
boatman  Offline OP
Senior Member
B

Joined: Apr 2014
Posts: 482
Sydney, Australia
Thanks jcl, much appreciated.

Page 7 of 7 1 2 3 4 5 6 7

Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1