Holy Graily Bob

EA's inspired by nanningbob's work here, especially those based on his 240 Moving Average trend detection filter.
Locked
User avatar
milanese
TechAdmin
Posts: 3293
Joined: Wed Jan 09, 2013 9:02 am
Location: btr rdx, r8 +

Holy Graily Bob

Post by milanese »

SteveHopwood » Sat Apr 18, 2015 10:46 am wrote:Does anybody know a way to allow one Empty4 platform send a Global Variable to another platform?

Here is what I am thinking. We have a demo account that we use for HGB. There is a little manager on the demo that places a 'don't trade yet guys' Global Variable on our real trading platform. Once the demo account has gone into DD by x pips, the manager sends the trading account a Global that says, 'up and at them tigers cos the retrace has happened.' Then, when the demo has made its usual profit run of 1000 pips it replaces the 'don't trade yet guys' back on the trading platform.

So far as I know, EA's can only read/write files from and to specified folders in the installation folder, so we need a way of getting the messages from the demo platform to the trading platform.

:xm:
this https://www.mql5.com/en/articles/1361 could be interesting...

Cheers :)

Tommaso
Global Prime is the official SHF broker :yahoo:
Searching for Servers and Workstations with individual configuration?
Just PM
:smile: Click here to go to the BoardKnowledgeBase
NOTE: Cookies and JavaScript are required for the using the board, with full functionality
art
Trader
Posts: 588
Joined: Fri Mar 02, 2012 3:51 pm

Holy Graily Bob

Post by art »

Hi rene, interesting your results are different to mine, i'm with global prime, using the same pairs as you and the same period this week as you, and you can see the difference, i'm also using ootb settings 4 hour charts
You do not have the required permissions to view the files attached to this post.
art
Trader
Posts: 588
Joined: Fri Mar 02, 2012 3:51 pm

Holy Graily Bob

Post by art »

forgot to add ignore the XAUUSD trades
User avatar
SteveHopwood
Owner
Posts: 9904
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Holy Graily Bob

Post by SteveHopwood »

Thanks guys. I will have a look.

I also had a browse round mql help and it looks as though this is addressed through come commands that I had not seen before. One is FILE_COMMON - The file path in the common folder of all client terminals \Terminal\Common\Files. Flag is used in FileOpen(), FileCopy(), FileMove() and in FileIsExist() functions.

Anybody here used them? It would be great to have some code snippets to hack.

:xm:
Read the effing manual, ok?

Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.

I still suffer from OCCD. Good thing, really.

Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.

To see The Weekly Roundup of stuff you guys might have missed Click here

My special thanks to Thomas (tomele) for all the incredible work he does here.
User avatar
SteveHopwood
Owner
Posts: 9904
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Holy Graily Bob

Post by SteveHopwood »

I have what I need. It turns out there is a 'common' folder and every Empty4 installation knows where it is. It is accessed using FILE_COMMON as one of the FileOpenRead/Write parameters, as in

Code: Select all

string file = "HGB trade command";
  //--- open the file
   ResetLastError();
   
   //Open for writing
   int file_handle = FileOpen( file, FILE_READ|FILE_CSV|FILE_COMMON );
I just used a script to open a file to write "Ehup" and popped this at the start of HGB's OnInit() to see if it works, and it does:

Code: Select all

   if (Symbol() != "EURUSD") return(0);
   string file = "HGB trade command";
  //--- open the file
   ResetLastError();
   
   //Open for writing
   int file_handle = FileOpen( file, FILE_READ|FILE_CSV|FILE_COMMON );
   if ( file_handle != INVALID_HANDLE ) 
   {
      string text = FileReadString(file_handle);
      FileClose(file_handle);
      Alert(text);
   }//if ( file_handle != INVALID_HANDLE ) 
   else
      Alert("Failed to open %s file, Error code = %d",file,GetLastError());
I duly get an Alerts saying, "Ehup" when I do an HGB recompile.

Lovely.

:xm:
Read the effing manual, ok?

Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.

I still suffer from OCCD. Good thing, really.

Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.

To see The Weekly Roundup of stuff you guys might have missed Click here

My special thanks to Thomas (tomele) for all the incredible work he does here.
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

Holy Graily Bob

Post by renexxxx »

Another way to communicate between two instances of Empty4, is by using SharedVar from fx1.net. I have been using this in the past and it works extremely well. You need to run a SharedVar server process, which is basically an in-memory database. For time-critical communication, this is the best option.
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

Holy Graily Bob

Post by renexxxx »

art » Sat Apr 18, 2015 9:59 pm wrote:Hi rene, interesting your results are different to mine, i'm with global prime, using the same pairs as you and the same period this week as you, and you can see the difference, i'm also using ootb settings 4 hour charts
Hi Art,
Your results are different, but not too different.

I am only trading: AUDUSD, EURGBP, EURJPY, EURUSD, GBPJPY, GBPUSD, NZDUSD, USDCAD and USDJPY.

In your results, you also have GBPCAD, USDCHF and XAUUSD. Still we have roughly the same amount of PIPs.

I have found that HGB works really well on EURUSD (Week 1: 590 PIPs, Week 2: 495 PIPs, Week 3: 62 PIPs, Week 4: 209 PIPs, Week 5: 40 PIPs, Week 6: 312 PIPs) for a total of 1707 PIPs over 6 weeks. I never had a negative week for EURUSD, although in week 3 the total HGB result was negative (-168 PIPs).

However, this is only a 6 weeks test and it would be too early to draw any conclusions.
trader689
Trader
Posts: 674
Joined: Thu Nov 17, 2011 12:53 am

Holy Graily Bob

Post by trader689 »

hey steve,is it possible to ask for an update regarding this method? many thanks
SteveHopwood » Wed Apr 01, 2015 6:02 pm wrote:Early days, but this week this tactic has worked well for me: set HGB going as early as possible in the London session; use the basket manager to close all the trades at $30 profit (0.01 lots GP account) and have HGB set to stop trading for the day once this profit level is achieved.

I then close down the platform and do not allow any further trading until the next London session.

Don't know if this is a long-term winning strategy and we might still need a market-is-overextented filter; we shall see.

:xm:
Pipologist
Trader
Posts: 34
Joined: Tue Dec 16, 2014 12:57 am
Location: Crawley, UK.

Holy Graily Bob

Post by Pipologist »

renexxxx » Sun Apr 19, 2015 12:34 am wrote: Hi Art,
Your results are different, but not too different.

I am only trading: AUDUSD, EURGBP, EURJPY, EURUSD, GBPJPY, GBPUSD, NZDUSD, USDCAD and USDJPY.

In your results, you also have GBPCAD, USDCHF and XAUUSD. Still we have roughly the same amount of PIPs.

I have found that HGB works really well on EURUSD (Week 1: 590 PIPs, Week 2: 495 PIPs, Week 3: 62 PIPs, Week 4: 209 PIPs, Week 5: 40 PIPs, Week 6: 312 PIPs) for a total of 1707 PIPs over 6 weeks. I never had a negative week for EURUSD, although in week 3 the total HGB result was negative (-168 PIPs).

However, this is only a 6 weeks test and it would be too early to draw any conclusions.
Hi Rene,

I have a question. Can you please clarify if you got the 6 weeks result for EURUSD with HGB in conjuction with BasketMirror EA, or with manual intervention, or just hand off. The reason I am asking this question is because I am using PPoS at the moment and am contemplating on moving on to HGB with manual intervention, or perhaps with BasketMirror EA.

Any suggestion you make is greatly appreciated.

Cheers,

Farhad
When a person really desires something, all the universe conspires to help that person to realize his dream.”
― Paulo Coelho, The Alchemist
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

Holy Graily Bob

Post by renexxxx »

Pipologist » Mon Apr 20, 2015 3:03 pm wrote: Hi Rene,

I have a question. Can you please clarify if you got the 6 weeks result for EURUSD with HGB in conjuction with BasketMirror EA, or with manual intervention, or just hand off. The reason I am asking this question is because I am using PPoS at the moment and am contemplating on moving on to HGB with manual intervention, or perhaps with BasketMirror EA.

Any suggestion you make is greatly appreciated.

Cheers,

Farhad
Farhad,
The results I published in this post are purely from trading HGB hands-off, on H4, 24x5. For what it's worth, my results testing PPoS have not been that great, but you have to make up your own mind about what you want to trade.

Cheers ... Rene.
Locked

Return to “Thingy Bob EA's”