Hi, I think I have an idea on how to do the shift programmatically, can't really work on it today but I'll give it a try tonight and let you know if I can come up with something workingpadnoter » Yesterday, 16:46 wrote: [...]
- by re-calculating the chigh/clow just before checking for tp & pprofit
- but as any coders will see, I've hardcoded the 2 - it works today and only for June calcs! lol - it needs to be the month-end shift that we are calc'ing.
[...]
Once a Month EA
- Elixe
- Trader
- Posts: 98
- Joined: Tue Jun 04, 2013 6:44 pm
- Location: France
Once a Month EA
- Elixe
- Trader
- Posts: 98
- Joined: Tue Jun 04, 2013 6:44 pm
- Location: France
Once a Month EA
Here is the trade simulator modified, It will only take the high/low after the trading day trigger to calculate the profit.
I've also added a csvLog boolean to make the screen comment print in expert window in a convertible format you can quickly paste in Excel or Calc with ";" separator.
Just open the daily log (right click the expert logs and select open to access the log files)
As always, I suggest you wait for Steve's opinion regarding any changes I make to things he coded before using it
Steve, I have added a function at the end called getMonthAverageProfit that takes care of the averaging process, it is commented.
I've also added a csvLog boolean to make the screen comment print in expert window in a convertible format you can quickly paste in Excel or Calc with ";" separator.
Just open the daily log (right click the expert logs and select open to access the log files)
As always, I suggest you wait for Steve's opinion regarding any changes I make to things he coded before using it
Steve, I have added a function at the end called getMonthAverageProfit that takes care of the averaging process, it is commented.
You do not have the required permissions to view the files attached to this post.
- zader
- Trader
- Posts: 90
- Joined: Fri Jul 06, 2012 8:46 am
- Location: Rundown NW England
Once a Month EA
Trades away today
GP still demo for now, 21 pairs, Day 4, London open, TP 50%
I'll post updates every now and then.
Edit: Update
I week on and no TP's
It's been as low as -900pips but is slowly recovering to only -600 now.
GP still demo for now, 21 pairs, Day 4, London open, TP 50%
I'll post updates every now and then.
Edit: Update
I week on and no TP's
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Once a Month EA
Ehup guys. Take a peek at what Radar is getting up to at http://www.stevehopwoodforex.com/phpBB3 ... 556#p94556. It looks outstanding.

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.
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.
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Once a Month EA
Waiting for a few of my D7 trades to go to TP as well. Hey ho.zader » Mon Jul 07, 2014 5:53 am wrote:Trades away today![]()
GP still demo for now, 21 pairs, Day 4, London open, TP 50%
I'll post updates every now and then.
Edit: Update
I week on and no TP'sIt's been as low as -900pips but is slowly recovering to only -600 now.
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.
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.
- zader
- Trader
- Posts: 90
- Joined: Fri Jul 06, 2012 8:46 am
- Location: Rundown NW England
Once a Month EA
Not a good start to this week after recovering to -600 that more than doubled to over -1200, I'll be amazed if it can recover from here, so might be a good time to start the 2nd basket.zader » Mon Jul 07, 2014 5:53 am wrote:Trades away today![]()
GP still demo for now, 21 pairs, Day 4, London open, TP 50%
I'll post updates every now and then.
Edit: Update
1 week on and no TP'sIt's been as low as -900pips but is slowly recovering to only -600 now.
GP Day 9, 21 pairs OOTB TP
- zader
- Trader
- Posts: 90
- Joined: Fri Jul 06, 2012 8:46 am
- Location: Rundown NW England
Once a Month EA
quick update:
1st basket had 2 TP's
but is -1012
on the running trades.
2nd basket has had 3TP's
running trades are -1015 
1st basket had 2 TP's
2nd basket has had 3TP's
Last edited by zader on Mon Jul 21, 2014 6:39 am, edited 1 time in total.
-
excalibre30
- Trader
- Posts: 68
- Joined: Sat Mar 08, 2014 7:45 am
Once a Month EA
Currently, at -498 pips. Trade opened on Day 7. Set no TP. Used MPBM to monitor and hit tP as basket at 400 pips.
- Elixe
- Trader
- Posts: 98
- Joined: Tue Jun 04, 2013 6:44 pm
- Location: France
Once a Month EA
Here are the results so far with TP based on my modified averaging method :
Day 7, TP 33 : Net Pips -540 (11 trades reached TP for 510 pips), Floating : -1050
Day 7, TP 50 : Net Pips -500 (7 trades reached TP for 450 pips), Floating : -950
Day 7, TP 66 : Net Pips -430 (6 trades reached TP for 490 pips), Floating : -920
Day 7, TP 33 : Net Pips -540 (11 trades reached TP for 510 pips), Floating : -1050
Day 7, TP 50 : Net Pips -500 (7 trades reached TP for 450 pips), Floating : -950
Day 7, TP 66 : Net Pips -430 (6 trades reached TP for 490 pips), Floating : -920
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Once a Month EA
V 1d is in post 1. I noticed some odd thingies in relation to trading day of the month calculation and was somewhat aghast at what I saw when I looked at the code.
Guys, it is a tad scary that nobody else noticed. Do none of you ever look at the chart feedback? How much money do you all want to lose?
For those of you who want to preserve your hard-coded inputs, copy this over the top of the existing void GetTodayTradingDayNumber() function:

Guys, it is a tad scary that nobody else noticed. Do none of you ever look at the chart feedback? How much money do you all want to lose?
For those of you who want to preserve your hard-coded inputs, copy this over the top of the existing void GetTodayTradingDayNumber() function:
Code: Select all
void GetTodayTradingDayNumber()
{
//Calculate today's trading day relative to the open date of the MN1 candle
//Get the time of the MN1 open
double ctime = iTime(Symbol(), PERIOD_MN1, 0);
//Get the D1 shift of ctime
int shift = iBarShift(NULL, PERIOD_D1, ctime, false);
//shift--;//The calculation was out by one day on Sunday night June 1st at markets open time. Trying this to see if it is needed throughout the month.
//Iterate a loop to calculate the number of trading days between ctime and now
TradingDay = 0;
for (int cc = shift; cc >= 0; cc--)
{
//Ignore weekend candles
if (TimeDayOfWeek(iTime(Symbol(), PERIOD_D1, cc) ) == 6 || TimeDayOfWeek(iTime(Symbol(), PERIOD_D1, cc) ) == 0)
{
//cc--;
continue;
}//if (TimeDayOfWeek(iTime(Symbol(), PERIOD_D1, cc) == 6 ?? TimeDayOfWeek(iTime(Symbol(), PERIOD_D1, cc) == 7)
TradingDay++;
}//for (int cc = shift; cc > 0; cc--)
//Define today's trading status for display
DayTradingStatus = notrading;
if (TradingDay == SendTradesDay)
DayTradingStatus = opentrading;
else
if (TradingDay == CloseTradesDay)
DayTradingStatus = closetrading;
}//End void GetTodayTradingDayNumber()
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.
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.