Holy Graily Bob 'n Dotty 'n Bolly

EA's inspired by nanningbob's work here, especially those based on his 240 Moving Average trend detection filter.
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Holy Graily Bob 'n Dotty 'n Bolly

Post by SteveHopwood »

SERIOUS WARNING
  • Most Forex traders lose all their money.
  • Using the robot posted here in trading Forex does not guarantee success.
  • Trading this robot could lead to serious financial loss.
  • Trading this robot without understanding its underlying trading strategies guarantees traders will lose their money.
  • This is not a set-and-forget ea; there is no such thing and anyone who tries to claim there is, is either stupid or lying. This ea requires frequent manual intervention.
  • At best, a trading robot is only 90% as good as the manual strategy it trades. At best. At worst, it can be much less effective. If the strategy is rubbish, so is the robot.
  • To trade this robot, you have to understand:
MAKE SURE YOU READ THIS POST http://www.stevehopwoodforex.com/phpBB3 ... 41#p111241 There was a Forex bloodbath on Jan 15th 2015 that you need to know about.

This EA is experimental and MUST NOT be used on a live trading account yet.

HGBnDnB is an extension of the idea of replacing DottyBot's nonlagdot with alternative trade triggers. Details are in the user guide attached. You need to download two libraries because HGBnD will not run without them: This bot:
  • Determines the potential trade direction ('trend' if you prefer) from the time frame chosen in the TrendTimeFrame input - default 4 hours.
    • looks back over the previous TrendTimeFrameCandlesLookBack. No signal in this period means no trading.
    • look for a long trade trigger when he finds a large green trend arrow or a buy trend blue squiggly line.
    • look for a short trade trigger when he finds a large red trend arrow or a sell trend blue squiggly line.
  • The trade trigger will be the market approaching the outer Bollinger Bands.
    • BbPeriod, BbDeviation, BbShift and BbAppliedPrice are the EA equivalents to those of the BB indi.
    • The BB time frame is TradingTimeFrame.
    • DistanceFromBandPips (in the Trading style inputs) is how close to the outer bands you want the market to be before trading. I am doing everything on the H4, hence the default of 20. This needs to be lower on lower time frames.
  • The only difference so far is the trade trigger. Nearly everything else is pure Dottybot - I created this EA from the Dottybot shell.
The original idea was to trade the snap back from the extremes. The trades last week were breakout from the inside, so I do not know how good the idea is. We shall see.

First week of trading: H4 for HGI and BB; $10,000 open balance;
hgbndnb.png
Skip to http://www.stevehopwoodforex.com/phpBB3 ... 40#p145240 now and return when you have read it. That post explains the idea I had to combine full hedging with HGI.

I have implemented a version of full hedging and offsetting following the full hedge trade closure:
  • Imagine that there are 5 buys and 16 sells open. These are unbalanced by 11, which is greater than the default BuysAndSellsUnbalancedAt value of 10.
  • HGI takes over and awaits a buy signal at the close of the previous candle:
    • HGBnDnB will close the hedge when HGI generates a sell signal, so long as that hedge trade is in profit and OnlyCloseFullHedgeWhenInProfit is 'true'. He will close the hedge at a loss if there is an opposite direction signal and OnlyCloseFullHedgeWhenInProfit is 'false'; sounds bonkers to me but someone will want this facility.
      • OffsetOppositeLosersAgainstProfit tells HGBnD to use the profit from the closed full hedge trade to close opposite direction trades:
        • Imagine the buy hedge in this example made $2,000 profit and 10 losing sells can be closed at -$2,000. He closes the 10 trades.
    • He will then carry on offsetting and gridding as before.
HGBnDnB recognises full hedge trades by the FullHedgeComment, so do not change this once you have a full hedge in place. You can see all this in action with a Craptest in CrapergyTester:
  • GJ.
  • M5 time frame.
  • Open prices.
  • Not visual mode.
  • EA defaults.
  • Watch the graph. It will stop moving when there is a full hedge in place. There will be a sharp spike upwards on the blue line when the hedge is removed, followed by a gently falling curve as the offset losers are closed. The the graph will start to move again.


I have made the default HGI_Name input that of the version currently in Bob's thread. Watch this in future releases. I am privy to the code and so usually use that non-expiring version. I cannot promise to remember to change the name in future releases.

Have fun.

:xm:

Matters of general interest
Go here to download and run the script that will fill your platform's missing chart history: http://www.stevehopwoodforex.com/phpBB3 ... f=15&t=254
Read this post:
http://www.stevehopwoodforex.com/phpBB3 ... p?f=6&t=78 Newbie traders, read this for inspiration and warning. Those of you who have suffered losses, read it for inspiration.

Masterly summary of hedging: http://www.forexfactory.com/showthread. ... ost4977179

EA coding
I receive may requests to code EA's. Traders, if I code your EA for free, then I will share it here. If you want me to code your EA without sharing, then my fee is $100 payable into my paypal account. I explain why at http://www.stevehopwoodforex.com/phpBB3 ... ?f=15&t=79, at the bottom of the post.

Useful utilities/EA's/scripts -

-
You do not have the required permissions to view the files attached to this post.
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. [email protected] 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
TraderJoeForex
Trader
Posts: 1157
Joined: Fri Mar 08, 2013 10:29 pm
Location: South London

Holy Graily Bob 'n Dotty 'n Bolly

Post by TraderJoeForex »

... on a roll Steve :hi:
forexdj
Trader
Posts: 63
Joined: Fri Mar 22, 2013 4:40 am

Holy Graily Bob 'n Dotty 'n Bolly

Post by forexdj »

Steve. I just have to post this here, I know it's not the right place to do it but I just have to. I have learnt a lot from you guys, I can't pay. When u told me your wife aint feeling well, I started a prayer session just for you and your family... My friends, they are praying for you... Am fasting for your family... I don't have to say that but I just have to, coz I want well wishers to join me. I know we have good Christians here... please lets pray for Steve and his family. Miracles have happened in my life... I want them to happen to all of us....
UKIONA VYAELEA JUA VIMEUNDWA!
User avatar
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hi.

I made some fixes to the code and attached it as version 2. Explanation is here: http://www.stevehopwoodforex.com/phpBB3 ... 61#p146461

.
You do not have the required permissions to view the files attached to this post.
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
User avatar
SteveHopwood
Owner
Posts: 9754
Joined: Tue Nov 15, 2011 8:43 am
Location: Misterton - an insignificant village in England. Very pleasant to live in.

Holy Graily Bob 'n Dotty 'n Bolly

Post by SteveHopwood »

The version in post 1 is Thomas'. Many thanks Thomas. :clap: :clap: :clap: :clap: :clap: :clap: :clap: :clap:

:xm:
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. [email protected] 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
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hello.

Most of those nasty little bugs that annoyed us for so long have been found. Version 2a is in the first post.

Please note that we have MondayStartTradingTime (default "02.00") and FridayStopTradingTime (default "12.00") as SERVER time now instead of MondayStartTradingHour, FridayStopTradingHour, AllowSaturdayTrading and AllowSundayTrading in LOCAL time. Please adjust them to your preferences.

Explanations and advices for the DIYers are here: http://www.stevehopwoodforex.com/phpBB3 ... 30#p147229
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
User avatar
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hello.

I have uploaded version 2b to the first post. It fixes a problem where the bot gets stuck sending invalid orders in fast moving markets.

There are also new inputs for those traders that use brokers with more then 5 daily candles per week. You can now specify Saturday and Sunday trading times.

Explanation and advice for the DIYers are here: http://www.stevehopwoodforex.com/phpBB3 ... 29#p147429
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
User avatar
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hello.

I have uploaded version 2c to the first post. Explanation and advice for the DIYers are here: http://www.stevehopwoodforex.com/phpBB3 ... 40#p148131
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
User avatar
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hello.

I have uploaded version 2d to the first post. It fixes some points and should be close to a final release. Explanations are here: http://www.stevehopwoodforex.com/phpBB3 ... 64#p148264
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
User avatar
tomele
Administrator
Posts: 1166
Joined: Tue May 17, 2016 3:40 pm
Location: Germany, Forest of Odes, Defending the Limes

Holy Graily Bob 'n Dotty 'n Bolly

Post by tomele »

Hello.

I have uploaded version 2e to the first post. This contains some fixes and improvements. Please read the explanation here: http://www.stevehopwoodforex.com/phpBB3 ... 50#p148712
Happy pippin, Thomas :-BD

It ain't what you don't know that gets you into trouble.
It's what you know for sure that just ain't so.
(Mark Twain)

Keep the coder going: Donate
Post Reply

Return to “Thingy Bob EA's”