stevehopwoodforex.com
https://www.stevehopwoodforex.com/phpBB3/
Print view

White Box Slope
https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=737
Page 4 of 6
Author:  SteveHopwood [ Sun Aug 05, 2012 10:33 pm ]
Post subject:  Re: White Box Slope

We get closer.

Look at this:
Noname.gif
ModifyOrder() is trying to modify the stop loss of a close trade. Bad enough, but ModifyOrder() is only called when there is a fresh trade sent (which happened on my demo) when CrimIsECN is true, so the function is trying to modify the sl of a recently opened trade with the order number of a closed trade.

No need to respond to this guys. I am in my usual Sunday night state - slightly inebriated, and a bit surprised that I can spell inebriated without the help of the wavy red line. The function of this post is to remind me what I was talking about in the morning.

So, best if not too many replies bury this one. If they do, could someone please make a note of it so I can be pointed at it tomorrow. Hic

up

:D
Author:  fxozgirl [ Mon Aug 06, 2012 2:47 am ]
Post subject:  Re: White Box Slope

SteveHopwood wrote:
fxozgirl wrote:Steve, I set this EA a couple of days ago which has taken 3 trades so far, no pending orders, nothing closed yet.

But, I have been running WB only on Slopey Beast with Slowkeys settings on 4H which is going really well. One thing I have noticed is that if a pending order is placed and price then moves in the opposite direction and the trade is not taken, the pending order just waits until price comes back which may or may not occur for an indefinite period of time. Unlike TB where the opposite pending order is placed as well, trades taken, goes to profit (pending order deleted), start again.

Depending on how long it takes price action to return to the pending trade the set up may not still be valid, I have taken to manually deleting all pending orders once a day, if the setup is still valid, the EA just places it again, if setup is not valid, pending order is not replaced.

Is it possible to have the EA automate this process?
Shelley, sorry but you appear to be talking about two different EA's (Slopey Beast and TB) in a completely different thread to either of them. Granted I am tired, and slightly pissed (booze I mean, not fed up) so I might be on the wrong track here.

Having said that, why are you asking about SB and TB here? This thread is about WBS, not any other random EA.

:D
Sorry Steve, clearly I didn't explain myself well enough :oops: ...so I will try again this time hopefully without confusing anyone ;)
  • WBS is derived from Slopey Beast but only using the White Box component of the strategy.
  • In turn, Slopey Beast is derived from The Beast but only trades the White Box strategy in one direction (the trending direction as per slope levels)
The Beast potentially will trade the White Box in both directions (by placing a buy AND sell pending order) if price crosses both sides of the white box (triggering both pending orders) before TP is hit, however if only one side of the white box pending orders are taken and price moves up/down and TP is hit, the other pending order is deleted and the EA will wait for the next trading opportunity.

With the SB & WBS versions, the EA is only trading in one direction, with only 1 pending order placed. If there is a reversal of price (earthquake or whatever), there is a possibility that the pending order may never be hit, price will continue to move away from the pending, and in time the trading conditions that triggered the pending order in the first instance are no longer valid....
However the pending order will still be there for infinity or until price eventually comes back and triggers it but in all likelihood is no longer a valid setup. (I really hope I haven't :? you further :oops: )

So, in a nutshell, I suppose what I'm asking is can there be any expiry time on pending orders?

Personally, I am manually closing all pending orders once a day, which then allows the EA to read the charts again and place fresh pending orders if applicable, but I was just wondering if this could be automated?
Author:  SteveHopwood [ Mon Aug 06, 2012 10:23 am ]
Post subject:  Re: White Box Slope

V 1f is in post 1.

The missing sl/tp functions I described in an earlier post could not be called, so I have fixed this - also made some additions to these functions.

I cannot see any reason why wbt should attempt to modify the sl/tp of a closed trade, as happened last night. Not a clue what might have caused that.

:D
Author:  rwb181 [ Mon Aug 06, 2012 7:20 pm ]
Post subject:  Re: White Box Slope

SteveHopwood wrote:We get closer.

Look at this:
Noname.gif
ModifyOrder() is trying to modify the stop loss of a close trade. Bad enough, but ModifyOrder() is only called when there is a fresh trade sent (which happened on my demo) when CrimIsECN is true, so the function is trying to modify the sl of a recently opened trade with the order number of a closed trade.

No need to respond to this guys. I am in my usual Sunday night state - slightly inebriated, and a bit surprised that I can spell inebriated without the help of the wavy red line. The function of this post is to remind me what I was talking about in the morning.

So, best if not too many replies bury this one. If they do, could someone please make a note of it so I can be pointed at it tomorrow. Hic

up

:D
Hi Steve,
Don't know if you remembered this or not.
You asked for it to be brought back to your attention so, if that is still needed, here it is.
If not, sorry to have bothered you.
Have a great day!
Ron
Author:  SteveHopwood [ Wed Aug 08, 2012 1:43 pm ]
Post subject:  Re: White Box Slope

V 1g is in post 1.

Looking back at the trades that have hit their opposite-direction white-line stoploss, it looks as though this does not allow sufficient breathing space. It is not always easy to tell just how far the market moved back into the 'wrong' set of sixths because they are redrawn periodically. Eyeballing the chart arrow and the subsequent adverse move suggests that a more distant stop might allow the trade to prosper eventually.

I have added the ability to set the stops at the green, gold and magenta lines - the inputs are obvious.

I have tried an experiment. Details in 'Slope value and angle' in post 1.

:D
Author:  SteveHopwood [ Wed Aug 08, 2012 3:07 pm ]
Post subject:  Re: White Box Slope

I forgot to add the new closure conditionals to InsertStopLoss. This is not a problem so long as the SL modification was successful at order-send time, or your crim is not ECN.

Fix in ost 1. If you can, go to void InsertStopLoss(int ticket) and make sure the first code snippet has all the conditionals:

Code: Select all

if (StopLossPips == 0 && !CloseLoserAtMiddleWhite && !CloseLoserAtOppositeWhite && !CloseLoserAtGreen && !CloseLoserAtGold && !CloseLoserAtMagenta) return;//Nothing to do.
   
:D
Author:  cuzgeorge [ Thu Aug 09, 2012 10:19 am ]
Post subject:  Re: White Box Slope

Hi all, Steve,
hope this helps
v1g on chart, ridiculous slope level settings to try and get a trade.

eventually, eurusd took a sell trade when market took sudden dive,

This error popped up (picture) causing excessive cpu usage also.

also, 'experts' tab showing same error continuously.

i'm leaving position open to see what happens.

regards to all
cuz
Author:  cuzgeorge [ Thu Aug 09, 2012 10:26 am ]
Post subject:  Re: White Box Slope

Went back to OOTB settings and all normal again, position still in profit.
Author:  jiaxingx [ Thu Aug 09, 2012 11:05 am ]
Post subject:  Re: White Box Slope

how the ea backtest good or bad?
Author:  cuzgeorge [ Thu Aug 09, 2012 11:51 am ]
Post subject:  Re: White Box Slope

jiaxingx wrote:how the ea backtest good or bad?
here are latest OOTB as i run normally. No slow-downs like before.
running on 4 pairs and playing with settings at the moment. 2 position, 2 wins in tester.
All times are UTC Page 4 of 6