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 a set-and-forget ea so long as your inputs are correct.
- To trade this robot, you have to understand:
- How to use EA's.
- Bob's Moving Average filter.
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.
Scalpy is an offshoot from my experiments trading monthly charts which involves trading at the start of the month, in the direction of the previous month's movement.
I experimented with hourly scalping:
- Wait for a few minutes past the top of the hour to give all the new H1 candles to form.
- Trade in the same direction as the previous candle so long as that direction is confirmed by Bob's filter.
- Basket trading: 0.1 lots on a $10,000 opening balance. $100 basket take profit.
- Close the trades at the end of the hour if they have not hit TP.
- Rinse and repeat.
I teach in schools four afternoons a week, needing to leave home at c. midday. I experimented on demo in the mornings and after returning home, with mixed success. The Easter break arrived and I had more time to spend on this and it quickly became obvious that the most successful hour to trade was the New York open at 1.00 pm London time.
The baskets would often hit TP quickly so I would be looking to exit after a couple of hours if this had not happened. Come 3.00 pm, I would be looking to exit at break even or better. Come 5.00 pm, close down and take the hit. Tomorrow is another day.
Scalpy Original
I wrote Scalpy so he could do the business for me whilst I am out. A lot of the inputs are familiar so I will not describe them.
These concern times to trade and to exit. They are all 24 hour local time, not broker time:
- TradingHour: the hour to start looking for trades. The default of 13 is New York opening i.e. 1.00 pm London time.
- TradingMinutes: the number if minutes to wait to allow all the new H1 candles to form. Scalpy sends the orders at 13.05 (1.05 pm) London time.
- BreakEvenStartHour: the hour at which to look for breakeven closure if the position has not hit TP. This defaults to 3.00 pm London time.
- AutomaticCloseHour: the hour at which to close all orders regardless of UPL. This defaults to 5.00 pm London time.
The take profit target inputs are:
- CashProfitTarget: this is a 'hard' TP. This defaults to $100 trading 0.1 lot sizes.
- UseDynamicCashTP: the number of pairs that pass Bob's filter usually vary from 8 to 19 so I decided to add a dynamic TP feature i.e. x dollars per order.
- CashUnitPerPair: the number of dollars per trade, defaulting to 10: 8 orders = $80 TP; 18 orders = $180 TP and so on.
I am writing this on May 14th 2022. The balance on the demo is just shy of $11,000 i.e. a profit so far of $994. This includes the losses I made whilst experimenting. The position since I started using Scalpy during the Easter break is brilliant:
Scalpy pic.png
Last week on the fixed $100 TP saw one basket close at BE whilst the other four raced to TP within 30 minutes or so. The jury is still out on the dynamic TP as I only coded it last weekend.
I have attached the script I wrote back at the start of my experimentation for any who want to experiment. Scalpy is the EA and is as near to set-and-forget as I have ever coded. Try it for yourselves.
Trading more than once a day with either the EA or the script
Both the script and EA make a note of today's trading day in a Global Variable:
- This is a tiny file that lives on you platform.
- Both the EA and script save a value to this file that represents today. 0 = Sunday; 1 = Monday and so on.
Both pieces of software look for this file and will not trade again if the value it holds represents today. In order to trade again on the same day:
- Remove Scalpy.
- Press the F3 key to call up the list of GV's on your platform. There will be umpteen if you are running TDesk.
- Highlight and delete the GV with the name, "Hourly scalper EA latest trading day."
- Rerun either Scalpy or the script with your chosen inputs.
This is a trade once a day idea, so don't blame me when thingies go wrong. Alternatively, crow with delight should you find better settings. Good luck.
Edit 27th May 2022
There has been a lot of crowing with delight so I developed a version that could trade multiple times a day. Scalpy Original is the initial trade-once-a-day.
--------------------------------------------------------------------------------------------
Scalpy (multiple trading version)
Referring back to this being a once-a-day trading strategy, an appetite emerged quickly in the development of Scalpy, to be able to trade multiple hours during the trading day. Be warned that Scalpy is a dedicated H1 trader; I have no idea what will happen should you try other time frames. Just go with what we have for now, OK? He is doing reasonably well.
Some of the inputs have morphed:
- TimeSourceToUse: this was brought to our notice by bobifier in a fantastic contribution. I had heard of it before but was unaware of its significance. UTC is a worldwide constant time, so if it is 7.00 UTC where you are, it is 7.00 UTC in any other part of the world. 15.00 UTC anywhere else, it is 15.00 UTC where you are. This eliminates the need to work out what is your local time in relation to London and New York. These markets open at 7.00 UTC and 12 UTC respectively. This makes other calculations easy. You want to trade 4 hours into London? That is 11.00 UTC. I wish I had known this years ago. Thanks again, bobifier.
You can still use broker and local times if you want; that merely marks you down as insane.
- TradingHours is now a list separated by commas between each element. Do not leave spaces or a comma at the end. The default trades the open of the London and New York markets in London time.
- TradingWaitMinutes is added to the hour inputs in TradingHours. By default, Scalpy will open baskets at 8.05 and 13.05 London time.
- BreakEvenStartWaitingHours tells Scalpy to wait this number of hours (rounded down) before looking for a break even closure opportunity. For example and by default:
- Orders opened at 8.05. Scalpy will start looking to close out unsuccessful baskets at 10.00
- AutomaticStartCloseHour tells Scalpy to wait this number of hours (rounded down) before closing a losing position. For example and by default:
- Orders opened at 8.05. Scalpy will close unsuccessful baskets at 12.00
Note to readers: the initial version of this multiple trading version was called Multiple Scalpy, shortened to MS. You will come across this abbreviation often.
--------------------------------------------------------------------------------------------
Installing updates
Empty4 does not automatically recompile .mq4 source code if the .ex4 file already exists, so to install an update:
- Open the Experts folder from within the platform:
- Click File/Open data folder/MQL4/Experts.
- Go back to the Navigator window, right click on Scalpy then select Delete.
- Keep the Data window open but close down the platform.
- Download the update and save it in the Experts folder.
- Restart the platform.
- Check that Scalpy's version number is correct - listed just underneath the time and date display.
Edit 9th Sept 2022
telaso wants to experiment with a basket stop loss calculated as a multiplier of the take profit. You will find this in the attached version - currently 1e.
The variable is StopLossTpMultiplier. You will find it in the inputs directly under the take profit target inputs. The default of zero disables the feature.
Demo accounts for you to follow if you do not want to open your own platforms:
- This is the original from where I started experimenting:
- Login : 2280519
- Investor : yx6usrz (read only password)
- This is the demo I started last week, using the dynamic TP feature:
- Login: 2295281
- Investor: jn5gada
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
-
- |