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

Bob and Shelley Again
https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=2759
Page 3 of 120
Author:  fxozgirl [ Mon Jul 29, 2013 8:52 pm ]
Post subject:  Re: Bob and Shelley Again

SteveHopwood wrote:We might need a minimum separation between the two moving averages.
eurcad.gh4.png
:D
Yes, I have this trade as well...
up to now I have been removing the EA (Test version) where the MA's are close/about to cross. But I've left this one on so we can watch/check that it is taking trades correctly and I want to see if the rules using RSI TMA Slope & Sto 5 can allow us to leave the EA on & protect us from getting into these trades.

So with that in mind, I actually think the rules should/would have prevented the trade from being taken.

Assuming this is a 'main' entry (close below 60 LWMA, close above 60 LWMA) , RSI TMA over the last 3 candles (immediately before the trade was taken) were Shift 1: 14.8896, Shift 2: 17.7102, Shift 3: 69.5945 whereas the rules are buy trades should be taken when RSI TMA is below 10.

If it is a 're-entry' trade using the Sto 5 as the trigger, Stochastic at Shift 2 was 24.5006 (should be below 20).

The levels on your chart appear to match mine Steve :D
Author:  fxozgirl [ Mon Jul 29, 2013 8:54 pm ]
Post subject:  Re: Bob and Shelley Again

SteveHopwood wrote: I am struggling a bit here, because this has not happened to my trades.

Looking at the code, I saw that the relevant functions such as double CalculateStopLoss(int type, double price) had the trade price passed as a parameter, but then price was reset to Ask/Bid within the functions.

Then, void CheckTpSlAreCorrect(int type) calls CalculateStopLoss(int type, double price) etc to ensure that the TP/SL are correct. As previously coded, CheckTpSlAreCorrect(int type) would call CalculateStopLoss(int type, double price) etc with the OrderOpenPrice(), which would be reset to Ask/Bid in CalculateStopLoss(int type, double price) etc.

So, my best guess is that the use of Ask/Bid in the sl/tp calculation functions is causing the problem. Not certain, mind.

Hey, don't we sound terribly clever discussing this stuff? :lol:

:D
Well Lordy...this is going to take some time for me to get my fledgling coding brain around this :lol: :lol:

But thank you for explaining :D
Author:  SteveHopwood [ Mon Jul 29, 2013 9:04 pm ]
Post subject:  Re: Bob and Shelley Again

I forgot to mention that V 1a in post one has the attempted fix for the sl/tp thingy.

:D
Author:  fxozgirl [ Mon Jul 29, 2013 9:09 pm ]
Post subject:  Re: Bob and Shelley Again

Summary of trades taken in first 24 hours:

AudCad - entry looks correct (according to rules) & currently at + 60pips (BE + 2 has been set)
audcad.gh4_130728.png
EurCad - incorrect entry as discussed 2 posts above & currently at -25 pips
eurcad.gh4_130729.png
GbpAud - correct 'main' entry, unfortunately EA set SL @ 47.5 pips (rather than 100) and stopped out, conditions were still correct 2 candles later & the EA obediently took another trade but was stopped out again @ 48 pips. If first trade was still running BE + 2 would have been set & currently at + 20 pips
gbpaud.gh4_130729.png
So all in all, given we're in test mode I think it's looking promising at these early stages :D
Author:  fxozgirl [ Mon Jul 29, 2013 9:16 pm ]
Post subject:  Re: Bob and Shelley Again

SteveHopwood wrote:I forgot to mention that V 1a in post one has the attempted fix for the sl/tp thingy.

:D

Looks like you fixed it, just put this on the chart, cleared my SL & TP and they appear to have been reset correctly.

Thanks Steve :D
Author:  SteveHopwood [ Mon Jul 29, 2013 10:01 pm ]
Post subject:  Re: Bob and Shelley Again

That eurcad is a correct entry. EA's work on absolute values at the time of working. What something subsequently looks like a on a chart is irrelevant.

On my chart, the candle shift 2 from the trade open closed below the fast ma by 0.00001 of a pip. Shift 1 closed above the fast ma, so the bot detected a cross upwards. RSI-TMA slipped below 10 during the trigger candle, and so the bot took the trade.

EA's do what they are programmed to do. You want them to do something different, you have to tell them to do it.

Welcome to my world. :lol:

:D
Author:  SteveHopwood [ Mon Jul 29, 2013 10:02 pm ]
Post subject:  Re: Bob and Shelley Again

fxozgirl wrote:
SteveHopwood wrote:I forgot to mention that V 1a in post one has the attempted fix for the sl/tp thingy.

:D

Looks like you fixed it, just put this on the chart, cleared my SL & TP and they appear to have been reset correctly.

Thanks Steve :D
My pleasure. This helped fill another gap in my shell code - always useful.

:D
Author:  OldTrader [ Tue Jul 30, 2013 4:13 am ]
Post subject:  Re: Bob and Shelley Again

curious, is JS working for you guys? On the audcad trade, JS isnt working here (BE did though).
Set a regular trailing stop for now, so will see on the next new trade if noone else is having issues
Author:  thomasmore [ Tue Jul 30, 2013 6:39 am ]
Post subject:  Re: Bob and Shelley Again

SteveHopwood wrote:We might need a minimum separation between the two moving averages.
eurcad.gh4.png
:D
Steve, I think we should consider two things combined: 1. the distance between the two LWMA's 2. the angle of the LWMA240. As can be seen in the picture, the two LWMA' can be equidistant but in a strong downtrend. So, a small distance between the two LWMA's does not necessarily means a ranging market.
Ludo
Author:  juliank [ Tue Jul 30, 2013 7:48 am ]
Post subject:  Re: Bob and Shelley Again

The AUDCAD trade is also missing by me even tough the EA was in place and the conditions ware met. The others are there and looking good. Anyway this system is great and can not wait to test it more :) .... tanks Steve and Shelly.
All times are UTC Page 3 of 120