forex software

Create and Test Forex Strategies

forex software

Skip to forum content

Forex Software

Create and Test Forex Strategies

You are not logged in. Please login or register.


Forex Software → Forex Strategy Builder Professional → Export EA to MT4 strategy tester hang

Pages 1

You must login or register to post a reply

RSS topic feed

Posts: 12

Topic: Export EA to MT4 strategy tester hang

Hi All,

I have been through the wiki videos and have made an EA using FSB pro (evaluating currently), all looks fine in FSB.  Exported it as an EA.mq4, imported it into MT4 editor, compiled it no problem .. but, when I attach to an offline chart to run strategy tester the tester just hangs after about 5 seconds .. nothing in the logs to see whats going on .. tester log and MT4 log etc .. I then enabled Write_Log_File=true; saved as a debug version, compiled, attached, re-ran the tester in MT4 and hangs, but can't see any logs being created other than the normal MT4 log and tester log .. I am sure its something simple .. any ideas ?

Windows 10
MT4 4.00 890
FSB 3.2.2.0

Re: Export EA to MT4 strategy tester hang

Hello 12tkram,

Do you set the starting date in the MT tester in order to allow it to load enough bars?
Is this expert runs on a normal chart?
If you have MT5, you can run it in a Debug mode in the tester. It may show the reason for the failure.

Re: Export EA to MT4 strategy tester hang

Hi Popov, yes, I have set the start and end dates, I have played around with different dates to see if its a historic data issue, but still the same.  I have also exported straight to MT4 from FSB and still the same issue .. I have tried it on a normal chart on a demo account and it doesn't error, but its not made any trades either, so, without knowing what its actually doing I cant say if its working or not.  I have seen some other threads which talk about indicators missing, I didnt specifically download any for the strategy, just used the ones in the generator and added a couple from the "add an opening logic condition" I have attached the strategy.  Thanks for your response, MarkT

Post's attachments

EURUSD M15 S1 opt2.xml 12.24 kb, 5 downloads since 2015-10-07 

You don't have the permssions to download the attachments of this post.

Re: Export EA to MT4 strategy tester hang

I don't see anything wrong with it:

http://s28.postimg.org/yn4h7viyx/screenshot_1226.jpg

Just exported it from FSB and run on the tester.

Re: Export EA to MT4 strategy tester hang

thanks for checking, OK, I wonder if its just hardware related as in not enough resource, I will investigate further .. thanks again smile

Re: Export EA to MT4 strategy tester hang

The expert uses 1050 bars in my MT4.
If I run it without "Use date" it prints an error:
http://s28.postimg.org/711pn6zm1/screenshot_1227.jpg

It works also on MT5.

I don't know what can be the reason.

If you are familiar with GitHub, you can find the latest modifications there: https://github.com/PopovMP/FSB_Expert_Advisor_Code. It is EA code v27. I'll update it officially this weekend.
You can try it. It has minor fixes.

7 (edited by 12tkram 2015-12-04 13:38:51)

Re: Export EA to MT4 strategy tester hang

thanks, I will give it a go ..

I came up with a couple of strategies, just playing around really to see if I could create somethign that actually worked.  The stragtegy I came up with seems to open trades ok, but, if I don't close them when they are in profit they just wait until they hit the stop loss.  They do go into profit, so it must be something to do with my closing slots ? maybe I need to add a trailing stop ? any hints tips to make it work a little better ?

Many Thanks
Mark

Post's attachments

USDJPY H1 046001 lots_0.1_2.0.xml 13.68 kb, 3 downloads since 2015-12-04 

You don't have the permssions to download the attachments of this post.

8 (edited by hannahis 2015-12-04 20:06:19)

Re: Export EA to MT4 strategy tester hang

Hi you are using the H1 time chart, are you aware that position wouldn't close at the end of the bar and in your case it may be at the end of the 1 hour bar closing.  So market will turn between this 1 hour but position will only close if conditions are met (even if it was 30 min before bar closing) at bar closing.

Last time I used H4 time chart and I also wondered why my position didn't close when all my indicators on my MT4 chart showed that my strategy closing conditions are met but due to "previous bar value" PBV feature, the positions wouldn't close till the end of the 4 hour bar even if conditions are met 3 hours ago...imagine I need to wait for 1-4 hours (depending when your conditions are met away from the next bar closing).  Initially, I wasn't aware about this PBV feature and I thought something wrong with my closing logic and I keep "improving and changing"....till I realised it got nothing to do with my logic anymore (once I understood what PBV meant).

Now I use only 1min time chart with LTF features as an alternative features.  Actually, it turned out as a blessing in disguise.  1 min time chart is super fast and responsive (if you know how to maximise it's potential) and with LTF (longer time frame), it's combining speed with the benefits of all other time frame advantages...

So I wonder whether in your case, whether PBV is one of your possible reason for the "delayed" closing in your trade positions...

Re: Export EA to MT4 strategy tester hang

hannahis wrote:

Hi you are using the H1 time chart, are you aware that position wouldn't close at the end of the bar and in your case it may be at the end of the 1 hour bar closing.  So market will turn between this 1 hour but position will only close if conditions are met (even if it was 30 min before bar closing) at bar closing.

Last time I used H4 time chart and I also wondered why my position didn't close when all my indicators on my MT4 chart showed that my strategy closing conditions are met but due to "previous bar value" PBV feature, the positions wouldn't close till the end of the 4 hour bar even if conditions are met 3 hours ago...imagine I need to wait for 1-4 hours (depending when your conditions are met away from the next bar closing).  Initially, I wasn't aware about this PBV feature and I thought something wrong with my closing logic and I keep "improving and changing"....till I realised it got nothing to do with my logic anymore (once I understood what PBV meant).

Now I use only 1min time chart with LTF features as an alternative features.  Actually, it turned out as a blessing in disguise.  1 min time chart is super fast and responsive (if you know how to maximise it's potential) and with LTF (longer time frame), it's combining speed with the benefits of all other time frame advantages...

So I wonder whether in your case, whether PBV is one of your possible reason for the "delayed" closing in your trade positions...

thanks Hannahis, so, when you say use 1min chart with LTF, I am not 100% sure what you mean, do you have any URLs/Links to any examples / documents ?

Cheers
Mark smile

Re: Export EA to MT4 strategy tester hang

H has mastered this approach. I was pretty skeptical of it but she seems to have  nailed it!

I think she uses M1 and then adds an indicator with TF 240 or 60 to give the strategy stability, At one time she posted her MyFx Book page.... impressive number of trades and I am sure much improved since then.

Re: Export EA to MT4 strategy tester hang

Blaiserboy wrote:

H has mastered this approach. I was pretty skeptical of it but she seems to have  nailed it!

I think she uses M1 and then adds an indicator with TF 240 or 60 to give the strategy stability, At one time she posted her MyFx Book page.... impressive number of trades and I am sure much improved since then.


Thanks BB, I will have a play around to see if I can make that work.

Re: Export EA to MT4 strategy tester hang

12tkram wrote:
Blaiserboy wrote:

H has mastered this approach. I was pretty skeptical of it but she seems to have  nailed it!

I think she uses M1 and then adds an indicator with TF 240 or 60 to give the strategy stability, At one time she posted her MyFx Book page.... impressive number of trades and I am sure much improved since then.


Thanks BB, I will have a play around to see if I can make that work.

I have tried adjusting the "longer time frame" setting for each of the indicators once M1 has been selected for the overall strategy timeframe .. and this does not work .. probably as a way of building new strategies I am sure it works, but as a fix for my strategy being able to exit trades in profit it doesn't work, and, I am not sure its what Hanahhis is describing anyway.

Hanahhis, can you give a little more detail to what your approach is please so I can see if I can apply it and see if it fixes my strategy ? many thanks in advance

Mark

Posts: 12

Pages 1

You must login or register to post a reply

Forex Software → Forex Strategy Builder Professional → Export EA to MT4 strategy tester hang

Similar topics in this forum