Moving Day Adapted

User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Moving Day Adapted

Post by SteveHopwood »

SERIOUS WARNING
  • Most Forex traders lose all their money.
  • Using the robot posted here in trading Forex does not guarantee success.
  • Trading this robot could lead to serious financial loss.
  • Trading this robot without understanding its underlying trading strategies guarantees traders will lose their money.
  • At best, a trading robot is only 90% as good as the manual strategy it trades. At best. At worst, it can be much less effective. If the strategy is rubbish, so is the robot.
  • To trade this robot, you have to understand:
MAKE SURE YOU READ THIS POST http://www.stevehopwoodforex.com/phpBB3 ... 41#p111241 There was a Forex bloodbath on Jan 15th 2015 that you need to know about. This sort of Black Swan event can happen at any second.

Rueben again. Everything is as Moving Day except for the trigger and the fact that there is no moving average, so download MD's user guide if you need info about the inputs.

As soon as MDA detects that the pair has no trades, he sends buy and sell stop orders 20 pips away from the market. He cancels the opposite stop order as soon as the other fills then adds the grid as usual.

The idea is to allow the market to decide in which direction we should trade, then take advantage of large moves in our direction. 5 days on demo have netted 12.3% gain trading 0.5 lot sizes and a global basket TP of $1,500.

There will be opposite direction stop orders sent for all the pairs you are trading. Once MaxPairsAllowed pairs have filled, all outstanding pairs of stop orders are deleted. They are replaced if a market order hits stop loss or take profit and off to the races we go again.

Rinse and repeat with the hope that all is done and dusted by mid afternoon on Friday and we can be flat for the weekend.

You can follow my demo if you want:
Login: 2186247
Investor: 0cnflnf


:xm: :rocket:


Matters of general interest
Go here to download and run the script that will fill your platform's missing chart history: http://www.stevehopwoodforex.com/phpBB3 ... f=15&t=254
Read this post:
http://www.stevehopwoodforex.com/phpBB3 ... p?f=6&t=78 Newbie traders, read this for inspiration and warning. Those of you who have suffered losses, read it for inspiration.

Masterly summary of hedging: http://www.forexfactory.com/showthread. ... ost4977179

EA coding
I receive may requests to code EA's. Traders, if I code your EA for free, then I will share it here. If you want me to code your EA without sharing, then my fee is $100 payable into my paypal account. I explain why at http://www.stevehopwoodforex.com/phpBB3 ... ?f=15&t=79, at the bottom of the post.

Useful utilities/EA's/scripts -

-
You do not have the required permissions to view the files attached to this post.
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. [email protected] 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.
danjuma
Trader
Posts: 68
Joined: Mon Jun 10, 2013 4:14 pm

Moving Day Adapted

Post by danjuma »

Hello Steve. Thanks for this. Just a couple of questions, unless I am missing something but there does not appear to be an option to select the pairs one wants MDA to trade, and no field to input the percentage of balance or equity to use per trade (not sure whether this was meant to be an option or not).
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Moving Day Adapted

Post by SteveHopwood »

danjuma » Sat Jun 13, 2020 10:17 pm wrote:Hello Steve. Thanks for this. Just a couple of questions, unless I am missing something but there does not appear to be an option to select the pairs one wants MDA to trade, and no field to input the percentage of balance or equity to use per trade (not sure whether this was meant to be an option or not).
Oops. These were thingies I meant to unhide before releasing the bot. I forgot. Fixed in 1c in post 1.

Of course, anyone with a firing brain cell who has made even the vaguest attempt at following my work here at SHF will already have worked out how to fix this, but the fix is in post 1 for the lazy dimwits unable to think for themselves. Said dimwits abound everywhere, so thanks for pointing this out.

:xm: :rocket:
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. [email protected] 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.
softballmel
Posts: 9
Joined: Wed Jun 27, 2012 2:48 am

Moving Day Adapted

Post by softballmel »

hi steve, do u have e demo login details for this adapted account?
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Moving Day Adapted

Post by SteveHopwood »

softballmel » Sun Jun 14, 2020 12:49 am wrote:hi steve, do u have e demo login details for this adapted account?
Added to post 1.

:xm: :rocket:
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. [email protected] 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.
danjuma
Trader
Posts: 68
Joined: Mon Jun 10, 2013 4:14 pm

Moving Day Adapted

Post by danjuma »

Hello Steve and thanks for this new toy. I am trying to demo and I have noticed a few 'errors' so far:

(1) The 'Percentage based lot sizing' does not appear to be working. I inputted 0 in the 'Lot' field under 'Hard lot sizing' to deactivate this and inputted 1 in the 'Risk Percent' field under ''Percentage based lot sizing'. 'Use Balance' under 'Account size lot sizing' was also set to true just in case. However, the EA displays 0.0 lot and freezes (timer not counting, no trades sent sent, and trying to remove the EA freezes Empty4). Screenshot attached below.

(2) With the first trades sent by the Grid, even though I inputted a stop loss of 75 pips in the 'StopLossPips' field under 'Hard stops', the 'StopOrderDistancePips' under the 'First Trades' field is added to the stop loss. For example I inputted 20 in the 'StopOrderDistancePips', MDA sent a buystop for AudChf at price 0.65058 and stop loss of 0.64108 (95 pips below) instead of 0.64308 (75 pips below). So, the 20 pips have been added to the 75 pips stop loss.
I don't know whether the same thing applies to subsequent grid trades (as non has been initiated so far; just starting to demo it) and to TP (as I am not using target profits).

I hope I am not completely mistaken and chatting BS, but if I am, please accept my apology and ignore me. Thanks.
You do not have the required permissions to view the files attached to this post.
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Moving Day Adapted

Post by SteveHopwood »

danjuma » Mon Jun 15, 2020 10:27 am wrote:Hello Steve and thanks for this new toy. I am trying to demo and I have noticed a few 'errors' so far:

(1) The 'Percentage based lot sizing' does not appear to be working. I inputted 0 in the 'Lot' field under 'Hard lot sizing' to deactivate this and inputted 1 in the 'Risk Percent' field under ''Percentage based lot sizing'. 'Use Balance' under 'Account size lot sizing' was also set to true just in case. However, the EA displays 0.0 lot and freezes (timer not counting, no trades sent sent, and trying to remove the EA freezes Empty4). Screenshot attached below.

(2) With the first trades sent by the Grid, even though I inputted a stop loss of 75 pips in the 'StopLossPips' field under 'Hard stops', the 'StopOrderDistancePips' under the 'First Trades' field is added to the stop loss. For example I inputted 20 in the 'StopOrderDistancePips', MDA sent a buystop for AudChf at price 0.65058 and stop loss of 0.64108 (95 pips below) instead of 0.64308 (75 pips below). So, the 20 pips have been added to the 75 pips stop loss.
I don't know whether the same thing applies to subsequent grid trades (as non has been initiated so far; just starting to demo it) and to TP (as I am not using target profits).

I hope I am not completely mistaken and chatting BS, but if I am, please accept my apology and ignore me. Thanks.
Re 1) you are possibly confusing the EA. I don't know. Nor do I care. The risk percent lot size code is not mine and I do not understand it.

Re 2) thanks for the heads up. This is an example of my lack of attention to detail - I had not noticed. TP and SL were being calculated from the market price not the stop order price. Fixed in 1d in post 1.

To DIY, go to void sendInitialPair(string symbol, int pairIndex) and replace the existing code with this:

Code: Select all

void sendInitialPair(string symbol, int pairIndex)
{
   //Sends the initial pair of stop orders
   
   if (!marginCheck() )
      return;//Insufficient margin to allow a new trading cycle
      
   if (!isTradingAllowed(symbol, pairIndex) )
      return;   
   
   
   
   
   double stop = 0, take = 0, price = 0;
   bool result = false;
   
   //Buy stop
   while (!result)
   {
      while (IsTradeContextBusy() )
         Sleep(1000);
         
      getBasics(symbol);   
      price = ask + (stopOrderDistance / factor); 
      stop = calculateStopLoss(symbol, OP_BUY, price);
      take = calculateTakeProfit(symbol, OP_BUY, price);
      
      result = sendSingleTrade(symbol, OP_BUYSTOP, TradeComment, Lot, price, stop, take);
   
   }//while (!result)
   

   //Sell stop
   result = false;
   while (!result)
   {
      while (IsTradeContextBusy() )
         Sleep(1000);
         
      getBasics(symbol);
      price = bid - (stopOrderDistance / factor); 
      stop = calculateStopLoss(symbol, OP_SELL, price);
      take = calculateTakeProfit(symbol, OP_SELL, price);
      
      result = sendSingleTrade(symbol, OP_SELLSTOP, TradeComment, Lot, price, stop, take);
   
   }//while (!result)
   
   countOpenTrades(symbol, pairIndex);

}//void sendInitialPair(string symbol, int pairIndex)
:xm: :rocket:
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. [email protected] 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.
danjuma
Trader
Posts: 68
Joined: Mon Jun 10, 2013 4:14 pm

Moving Day Adapted

Post by danjuma »

Many thanks for rectifying the stop loss issue Steve. Much appreciated.

With regards to your statement:
Re 1) you are possibly confusing the EA. I don't know. Nor do I care. The risk percent lot size code is not mine and I do not understand it.
Below is what I am referring to (in the settings for MDA v1c.
You do not have the required permissions to view the files attached to this post.
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Moving Day Adapted

Post by SteveHopwood »

I still don't care about RiskPercent. Merely repeating the problem will not make me care.

Something has gone wrong folks, on my demo at least. MDA is suddenly deleting all the grid stop orders, or not sending them in the first place. I will look into this later. The fixes I added must have buggered thingies up as the grid was being sent perfectly last week.

Hey ho.

:xm: :rocket:
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. [email protected] 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.
softballmel
Posts: 9
Joined: Wed Jun 27, 2012 2:48 am

Moving Day Adapted

Post by softballmel »

Good work Steve! Moving day adapted is doing brilliantly! Do let us know once u fix the bug :)
Post Reply

Return to “Moving Day”