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

Bob and Shelley Again
https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=2759
Page 91 of 120
Author:  milanese [ Sat Dec 07, 2013 8:06 pm ]
Post subject:  Re: Bob and Shelley Again

velicox wrote:where i can download the last version?
Hi,

the latest one you will always find at page 1 of this thread, please read carefully the userguide, and the entire thread..

Cheers :)

Tommaso
Author:  Mocean [ Sat Dec 07, 2013 10:15 pm ]
Post subject:  Re: Bob and Shelley Again

Thanks Garyfritsz,
BTW don't assume optimizing this would accomplish any magic. This indicator is basically tuning to the "frequency" of the market. The faster the pair cycles up/down/up/down, the shorter your lookback and EMA should be. But the market frequency changes all the time. You might find a lookback that works better in most conditions than 10, but no lookback is always right.
Yes agreed - however I do think an appropriate lookback is somewhere between 5-15, and some backtesting would gve me more confidence in that. Too small = more entries and more losses, to big = less entries and less profit.

Though it is the optimal combination of lookback and Trend Line Angle (TLA) we seek.

So from these charts we see the first entry on UJ encountered a sudden dip shortly after, in the current market I am usually using 100pip SL until 30-50pips clear for BE, so this might have been OK.

Uptrend BUY Entries - Crosses Zero from Below
USDJPY.gif

Downtrend SELL Entries - Crosses Zero from Above
audusd.gif
I took a closer look at the AUD signal in red above, not every one can be a winner. I think a SL at the previous high would limit the pain. Although it does come back into profit you could let it run but that's a lot of draw down. Even stopped out the success rate on the AUD/USD pair alone is 3/4 (75%).

You could use the ZigZag indi which ZUP Harmonics uses to get the previous high/low. I've attached 2 versions but I don't know how they differ?
ZigZag_new_nen4.mq4
ZigZag.mq4
screenshot_11.jpg
Here's the same chart with 15 candle lookback "15 TLA" in green. It misses the false sell signal and actually picks up the correct sell signal 1 candle earlier.
screenshot_13.jpg
Garyfitz - could you indulge me and run these charts again with c-15 lookback?

Are you curious enough to script this to run with the 60/240 MA and test it?

I think it might be better to use trigonometry functions in a script to get the TLA on candle close to give an easier understanding of what's actually going on.

Cheers,
Andrew
Author:  garyfritz [ Sun Dec 08, 2013 12:42 am ]
Post subject:  Re: Bob and Shelley Again

You might want to consider watching the direction of that signal (increasing or decreasing) rather than just the zero crossing.

But if you want to pursue this further, please start a new thread. We've already distracted from the focus of this thread (BASA) long enough.
Author:  Wapen [ Mon Dec 09, 2013 7:14 pm ]
Post subject:  Re: Bob and Shelley Again

Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen
Author:  SWG123 [ Mon Dec 09, 2013 7:48 pm ]
Post subject:  Re: Bob and Shelley Again

Wapen wrote:Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen
Hi Wapen, I think you need this function:-

Code: Select all

 //~ Closure suggestion by spotdespot:
   //~ I believe you should save significant pips if you introduce a rule whereby the trade should close if (for a sell) the H4 entry candle closes higher than the entry (open) price AND the following candle also closes higher than its open price (and vice-verse for buys). 
   //Applies only when there are no stack trades.
   if (OpenTrades == 1)
   {
      if (!OrderSelect(TicketNo, SELECT_BY_TICKET, MODE_TRADES) ) return;//In case the trade has closed
      int shift;//For the iBarShift to get the candle shift of the trading candle
      static datetime OldTime = 0;//Only need the test at the start of each candle
      if (OldTime != Time[0])
      {
         bool CloseThisTrade = false;
         OldTime = Time[0];
         if (OrderProfit() < 0)
         {
            shift = iBarShift(NULL,Period(),OrderOpenTime(), false);
            if (shift == 2)
            {
               if (OrderType() == OP_BUY)
               {
                  if (iClose(NULL, SpotdespotCandleCloseTf, shift) < iOpen(NULL, SpotdespotCandleCloseTf, shift))
                  {
                     if (iClose(NULL, SpotdespotCandleCloseTf, shift - 1) < iOpen(NULL, SpotdespotCandleCloseTf, shift - 1))
                     {
                        CloseThisTrade = true;
                     }//if (iClose(NULL, SpotdespotCandleCloseTf, shift - 1) < iOpen(
                  }//if (Close[shift] < Open[shift])               
               }//if (OrderType() == OP_BUY)
               
               if (OrderType() == OP_SELL)
               {
                  if (iClose(NULL, SpotdespotCandleCloseTf, shift) > iOpen(NULL, SpotdespotCandleCloseTf, shift))
                  {
                     if (iClose(NULL, SpotdespotCandleCloseTf, shift - 1) > iOpen(NULL, SpotdespotCandleCloseTf, shift - 1))
                     {
                        CloseThisTrade = true;
                     }//if (iClose(NULL, SpotdespotCandleCloseTf, shift - 1) < iOpen(
                  }//if (Close[shift] < Open[shift])               
               }//if (OrderType() == OP_SELL)
            }//if (shift == 2)               
         }//if (OrderProfit() < 0)
      }//if (OldTime != Time[0])

      if (CloseThisTrade)
      {
         result = CloseTrade(TicketNo);
         //Actions when trade close succeeds
         if (result)
         {
            DeletePendingPriceLines();
            TicketNo = -1;//TicketNo is the most recently trade opened
            OpenTrades--;//Rather than OpenTrades = 0 to cater for multi-trade EA's
         }//if (result)
      
         //Actions when trade close fails
         if (!result)
         {
            OldTime = 0;//Force a retry at the next tick
         }//if (!result)
      }//if (CloseThisTrade)

      return;//No need for the stack basket code
   }//if (OpenTrades == 1)
Author:  SteveHopwood [ Mon Dec 09, 2013 9:21 pm ]
Post subject:  Re: Bob and Shelley Again

Wapen wrote:Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen
SWG is correct and you will find the snippet within void CountOpenTrades()

The code had to go there rather than within the more obvious bool LookForTradeClosure(int ticket) because the spotdespot closure filter can only be used on the Main/Reentry trade. We do not want it applying to stack trades. I could probably have used the existing variables to move the spotdespot filter from its current location to bool LookForTradeClosure(int ticket), but it aint bust so I am not fixing it, for now at least. Maybe sometime later.

Hope this makes some vague glimmering of sense. It would be a first if me and a description of my coding did so.

:D
Author:  TonkaTuff [ Mon Dec 09, 2013 10:00 pm ]
Post subject:  Re: Bob and Shelley Again

Wapen wrote:Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen

Hi Wapen,

Could you possibly post your .set file and pairs you are trading please? Are you using BASA to close your basket, or another method?

Thanks,
TT
Author:  SteveHopwood [ Mon Dec 09, 2013 10:14 pm ]
Post subject:  Re: Bob and Shelley Again

TonkaTuff wrote:
Wapen wrote:Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen

Hi Wapen,

Could you possibly post your .set file and pairs you are trading please? Are you using BASA to close your basket, or another method?

Thanks,
TT
I occasionally give thought to banning the posting of setfiles. Over the coming break, I will give it some serious thought.

How can I put this given that: different criminals = different feeds = different results. Hell's Bells, but here I have even posted different results on two different live accounts from the same criminal.

I know how to put it. Only an idiot relies on the setfile posted by someone else for his own trading, in the teeth of the howling blizzard of evidence that this lunatic behaviour costs said idiot money.

So, you can try and fail to adapt someone else's behaviour to your own ends and fail and lose cash, or you can do your own thinking for yourself and stop losing money. Possibly.

Guess how I know that trying to use someone else's setfiles will lose you cash. You can work stuff out for yourself or you can go bust. The choice is yours.

Sorry if this comes across as a tad blunt. It is the time of night when I have less patience than usual. Just because I am an irritable old fart doesn't mean I am wrong.

:D
Author:  Wapen [ Tue Dec 10, 2013 4:19 am ]
Post subject:  Re: Bob and Shelley Again

Hi, To update all. We had a vew thunderstorms here in Joburg SA, and had a vew computer crushes. Nothing series. With this Empty4 or the EA reverted back to standard TP. I have subsiquintly removed MPTM. I'm now playing around with the SL.

Some trades are closed manually. Depends on profit for the day I will close part of old trades!

All other stuff are OOTB.


Wapen





TonkaTuff wrote:
Wapen wrote:Hi, I just like watching BASA trade. Even the trades that close negative. This system on 4H will let you learn to be pasiant and trade when the market is ready.

Steve, Regarding the H1, can you please show me where in the code is the closes function of a trade after 2 candle in the other direction. (I want to test something related to this). Thank

Thanks Shelly for this excellent trading system and Steve for coding!!

Wapen

Hi Wapen,

Could you possibly post your .set file and pairs you are trading please? Are you using BASA to close your basket, or another method?

Thanks,
TT
Author:  TonkaTuff [ Tue Dec 10, 2013 4:52 am ]
Post subject:  Re: Bob and Shelley Again

Thanks for the update Wapen.

Cheers,
TT
All times are UTC Page 91 of 120