Joe. Swing-trade your way to a baby equity millipede

Post Reply
andydoc
Trader
Posts: 53
Joined: Sun Dec 11, 2011 8:26 am
Location: West Brom, UK

Re: Joe. Swing-trade your way to a baby equity millipede

Post by andydoc »

LOL

Any thoughts on numerous SL errors?

Don't worry about the close best half:close worst half argument - close worst is better
User avatar
SteveHopwood
Owner
Posts: 9904
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Re: Joe. Swing-trade your way to a baby equity millipede

Post by SteveHopwood »

andydoc wrote:LOL

Any thoughts on numerous SL errors?
Yes. Remove the reporting code so that the punters are less upset by them, then assure them that what they see in the tabs they consult mean nothing. Then ignore them.

Thing is, I have had Joe running on demo all day and not had an sl error. As I often point out to people, I find it impossible to clear up errors unless they occur on my platform.

When someone produces a problem that arose on a demo, I might be able to solve it or I might not. Most people lack the ability to report the prob in a way that makes any sense. Mostly, what they do is say, in effect, "It dunt wurk." and expect me to sort it out.

Mostly, I sort out problems when they occur on my demo. The rest I tend to ignore 'cos there is bugger all I can do about them.

:D
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.
User avatar
gaheitman
Trader
Posts: 655
Joined: Tue Nov 15, 2011 10:55 pm
Location: Richmond, VA, US

Re: Joe. Swing-trade your way to a baby equity millipede

Post by gaheitman »

andydoc wrote:LOL

Any thoughts on numerous SL errors?

Don't worry about the close best half:close worst half argument - close worst is better
Do we have a candidate version I should be looking at? I would like to go through it and make some changes so that we can easily (well, maybe not easily) track what is going on with the trades. I'd rather not make all those changes and have to move them to a new code base.

My plan is to have a global set of procedures along the lines of

LogOpenTrades() - print out a list of all the open trades with visual notification of breakeven, etc, similar to OrderPrint for each one, except it will automatically do Alerts instead of Prints when in strategy tester.
LogCommonVariables(), print out the contents of TicketNo, OpenTickets, BuyOpen, SellOpen, etc.
LogBasketStats() - print out summary statistics for all open trades, including total profit/loss, etc.

I'd also like to update SendSingleTrade and ModifyOrder to log what they've been asked to do and the results.

Maybe there would be a global LogLevel that controls the amount of information printed/alerted. Still gathering requirements, you see.

Reading Steve's post, it doesn't seem like I'm heading in the right direction... :D

George
andydoc
Trader
Posts: 53
Joined: Sun Dec 11, 2011 8:26 am
Location: West Brom, UK

Re: Joe. Swing-trade your way to a baby equity millipede

Post by andydoc »

LOL Steve, spoken like a true Yorkshireman! :D

George, I am concentrating on my variant which I shall post shortly, I would appreciate you having a look at that - it will, contrary to Steves POV have lots and lots of reporting code if I haven't been able to figure it out!
andydoc
Trader
Posts: 53
Joined: Sun Dec 11, 2011 8:26 am
Location: West Brom, UK

Re: Joe. Swing-trade your way to a baby equity millipede

Post by andydoc »

Ok, This is as good as I can make this. It doesn't take the initial FB trade as there are two many fakes. It aggressively stacks on the trends, with an exponential pyramiding multiplier ensuring positions on the trend are broad based.
If the drawdown is too great you can limit the lot down to .01 (I had it at .02 for the attached test, it may also be worth experimenting with the exponential power of the pyramiding if you do drop the lot size.
There are lots of alerts in there (sorry Steve) about where trade send and order modify have come from and their parameters, also one at the end which shows your Margin ratio (*100 to get % :D ) Margin Ratio remained above 500%. (lowest was 538%)

All we need now is a method to trade the flat bits of the equity curve :)

Code: Select all

Symbol GBPUSD (Great Britain Pound vs US Dollar) 
Period 4 Hours (H4) 2011.03.21 00:00 - 2011.05.26 20:00 (2011.03.21 - 2011.05.27) 
Model Every tick (the most precise method based on all available least timeframes) 

Bars in test 1295 Ticks modelled 3213689 Modelling quality 90.00% 
Mismatched charts errors 0     
 
Initial deposit 10000.00     
Total net profit 6070.61 Gross profit 9851.80 Gross loss -3781.19 
Profit factor 2.61 Expected payoff 54.69   
Absolute drawdown 87.92 Maximal drawdown 3019.74 (18.24%) Relative drawdown 18.24% (3019.74) 
 
Total trades 111 Short positions (won %) 71 (23.94%) Long positions (won %) 40 (32.50%) 
 Profit trades (% of total) 30 (27.03%) Loss trades (% of total) 81 (72.97%) 
Largest profit trade 1951.61 loss trade -544.64 
Average profit trade 328.39 loss trade -46.68 
Maximum consecutive wins (profit in money) 8 (2366.90) consecutive losses (loss in money) 14 (-465.17) 
Maximal consecutive profit (count of wins) 3231.17 (3) consecutive loss (count of losses) -930.87 (6) 
Average consecutive wins 2 consecutive losses 6 

StrategyTester Joe2 initial.gif
You do not have the required permissions to view the files attached to this post.
User avatar
SteveHopwood
Owner
Posts: 9904
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Re: Joe. Swing-trade your way to a baby equity millipede

Post by SteveHopwood »

andydoc wrote:Ok, This is as good as I can make this. It doesn't take the initial FB trade as there are two many fakes. It aggressively stacks on the trends, with an exponential pyramiding multiplier ensuring positions on the trend are broad based.
If the drawdown is too great you can limit the lot down to .01 (I had it at .02 for the attached test, it may also be worth experimenting with the exponential power of the pyramiding if you do drop the lot size.
There are lots of alerts in there (sorry Steve) about where trade send and order modify have come from and their parameters, also one at the end which shows your Margin ratio (*100 to get % :D ) Margin Ratio remained above 500%. (lowest was 538%)

All we need now is a method to trade the flat bits of the equity curve :)

Code: Select all

Symbol GBPUSD (Great Britain Pound vs US Dollar) 
Period 4 Hours (H4) 2011.03.21 00:00 - 2011.05.26 20:00 (2011.03.21 - 2011.05.27) 
Model Every tick (the most precise method based on all available least timeframes) 

Bars in test 1295 Ticks modelled 3213689 Modelling quality 90.00% 
Mismatched charts errors 0     
 
Initial deposit 10000.00     
Total net profit 6070.61 Gross profit 9851.80 Gross loss -3781.19 
Profit factor 2.61 Expected payoff 54.69   
Absolute drawdown 87.92 Maximal drawdown 3019.74 (18.24%) Relative drawdown 18.24% (3019.74) 
 
Total trades 111 Short positions (won %) 71 (23.94%) Long positions (won %) 40 (32.50%) 
 Profit trades (% of total) 30 (27.03%) Loss trades (% of total) 81 (72.97%) 
Largest profit trade 1951.61 loss trade -544.64 
Average profit trade 328.39 loss trade -46.68 
Maximum consecutive wins (profit in money) 8 (2366.90) consecutive losses (loss in money) 14 (-465.17) 
Maximal consecutive profit (count of wins) 3231.17 (3) consecutive loss (count of losses) -930.87 (6) 
Average consecutive wins 2 consecutive losses 6 

StrategyTester Joe2 initial.gif
Hehe. I have your version running on demo, and it is taking 0.32 lot trades not the 0.01 that I want. Is that you or me causing this?
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.
DragosDanescu
Trader
Posts: 118
Joined: Wed Nov 16, 2011 5:18 pm
Location: Oradea, Western Romania

Re: Joe. Swing-trade your way to a baby equity millipede

Post by DragosDanescu »

SteveHopwood wrote: Hehe. I have your version running on demo, and it is taking 0.32 lot trades not the 0.01 that I want. Is that you or me causing this?
Nope, Steve, same here, for some reason, base lot is disabled. This is taking over, instead:

Code: Select all

  //Lot size calculated by risk
      Alert(SendLots);
      SendLots = SendLots*(2^(5-OpenTrades));//Andydoc      
      Alert(SendLots);
      if (RiskPercent > 0) SendLots = CalculateLotSize(NormalizeDouble(stop, Digits), price);
Image
User avatar
SteveHopwood
Owner
Posts: 9904
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Re: Joe. Swing-trade your way to a baby equity millipede

Post by SteveHopwood »

DragosDanescu wrote:
SteveHopwood wrote: Hehe. I have your version running on demo, and it is taking 0.32 lot trades not the 0.01 that I want. Is that you or me causing this?
Nope, Steve, same here, for some reason, base lot is disabled. This is taking over, instead:

Code: Select all

  //Lot size calculated by risk
      Alert(SendLots);
      SendLots = SendLots*(2^(5-OpenTrades));//Andydoc      
      Alert(SendLots);
      if (RiskPercent > 0) SendLots = CalculateLotSize(NormalizeDouble(stop, Digits), price);
Cheers. That is just LUC and a bit of forgetfulness kicking in. Coders can cancel the mahoosive lot calculation. I shall let it run, for fun. :lol:

:D
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.
andydoc
Trader
Posts: 53
Joined: Sun Dec 11, 2011 8:26 am
Location: West Brom, UK

Re: Joe. Swing-trade your way to a baby equity millipede

Post by andydoc »

Hi Steve. Sorry, this will be brief as it is on the iphone but it is the pyramiding of the stack i.e. Start with a high lot position and add to it in reducing sizes. The idea is that the majority of the position wont get taken out by retracements but rather by the later 50 % culls
If you rerun my backtest with and without it you will see the benefit
andydoc
Trader
Posts: 53
Joined: Sun Dec 11, 2011 8:26 am
Location: West Brom, UK

Re: Joe. Swing-trade your way to a baby equity millipede

Post by andydoc »

Just for info if you do want to cancel it it also appears in HasSellFilled() and HasBuyFilled() in fact it is only those two that are effective as I have disabled the initial trade to get rid of the fakeouts
Post Reply

Return to “Automated trading systems”