Prototype 4 is an automated trading system, which opens positions in trend direction from correction based on data of built-in indicators. Test results show a stable profits for almost 15 years since 2000 (see. the screenshots), as well as in real trading.
This Expert Advisor can be used in combination with Prototype 1. Part of the orders of two Expert Advisors is hedged (opened in different directions).
The Expert Advisor works on any account with any deposit (USD, EUR, GBP, CHF, RUR etc.) on any currency pair and period, but adjustment of parameters can be required for specific currency pairs. The default settings are selected for EURUSD M15. The EA determines the lot size, adjusts the settings for the 5-digit server, identifies and adjusts to any deposit currency, as well as determines the time difference from GMT (for testing set the value of the deviation from GMT manually, because MetaTrader does not provides a time deviation for testing).
An important additional advantage of the EA is its resilience, since its code contains the mechanism of backup of files, in which the variables used in the program are stored. In case of failure, trading will be continued from the same place automatically. For each account, on which the EA is used, separate files, different from those of the other account, will be created.
When testing and optimizing, set ManualGMTOffset manually. It is calculated as the difference between the terminal time and GMT or UTC (not to be confused with London time).
For example: the terminal time is 15:02, while GMT is 12:02 (can be found on the Internet), so ManualGMTOffset = 15:02-12:02 = 3.
- The EA can trade witj any deposit, which is enough to open an order with a minimum lot. Therefore, choose a broker account with the minimum lot as little as possible, for a more accurate calculation of lots. I recommend 3000 with the minimum lot of 0.01 (if a cent account, then 30 dollars (3000 cents) per 0.01 of a cent lot).
- Choose a broker with the spread for EURUSD less than or equal to 2 points.
- Do not use the EA together with other Expert Advisors on the same account.
|extern double Risk=10||
Risk value. Values from 1 to 100. It is used for the calculation of lot and the profit value. The higher is the value, the higher is the risk.
|extern double ProfitFactor=2||Profit ratio. It is used for the calculation of the profit amount. Recommended values are between 0,1 and 3.|
|extern double LimitDayPrice=115||Trade restrictions based on the movement of a currency for one day. Orders are closeв, if the movement exceeds this value. Recommended values are between 80 and 120.|
|extern bool AutoGMT=true||
Calculation of difference between GMT and server time using the terminal function (does not work in testing and optimization).
If in real trading terminal gives the wrong deviation, then set the value to false, and set a required value in the ManualGMTOffset parameter.
|extern int ManualGMTOffset=3||Setting the difference between the terminal time and GMT (used for testing with any value of AutoGMT and in real trading with AutoGMT = false)|
|extern double ChangeLots=1.75||Lot change coefficient. Recommended values are from 1 to 2.|
|extern double StepLots=9||The distance between the orders. Recommended values are between 6 and 15.|
|extern int MaxOpenOrders=10||The maximum number of opened orders. As a rule, this parameter is not required, so the values are high, but can be set from 5-10 for a better control.|
|extern int Slippage=10||Acceptable slippage|
|extern int MagicNumber=1231||A unique number for opening orders|
|extern double StopLoss=1000||The Stop Loss level. As a rule, this parameter is not required, so the default value is high, but can be set to 40-120.|
2. The updated calculation of the lot, with a shortage of money.
3. Shifted to the information window to the right.
2. Fixed error occurring when working with certain brokers
3. Improved error handling
4. Added ability to work with ECN servers
5. Added the possibility to set the lot manually (settings AutoLot and StartLot)
2 Added warning if ResetFiles is enabled
3 Minor changes in code
2. The opportunity to work with any pair (Advisor is optimized for EURUSD M15, this pair is recommended to use)
3. Changed the names and the number of backup files (to be able to trade different pairs)
4. Changed information window
5. Added a vertical line, which mark the beginning of the trading period
6. Added the option in the settings CloseEndOfWeek (closing orders at the end of the week). Default True. They will closed 20:45 GMT and will be opened in next week.
7. Added the option in the settings ResetFiles (reset parameters, clears the parameters and writes them to files) default False.