Multi Symbol EA – Bug Fix

指定

Objective: Find/fix 3 Bugs

Tasks:

1)       Bug find/fix: automatically identify and exclude orders in the “placed” status

2)       Bug find/fix: understand why sometimes the position opens with double volume and solve it

3)       “Force close” positions after the max position time (existent parameter)

 

EA details:

The EA monitors 75 symbols identified in a CSV file placed on the FILE folder. The same CSV also contains a series of parameters that are used to control when to open and close positions.

The code contains 1200 rows, and the open signal is on the following part:

 

And the close signal is on this part:

 

Other important aspects of the EA:

-          Whenever MultiSymbol = False, EA will only runs for the graphic where the EA was apply to (single symbol) and all inputs will come from the input screen. This should also be the choice when backtesting.

-          Whenever MultiSymbol = True, EA will search for the for the .csv file and get the customized inputs for each symbol

-          When using the MultiSymbol, the graphical lines (TP, SL, etc) will only appear for the graph where the EA is applied. If you open another screen, the lines will not appear, but if you drag another symbol to the same graph, the lines will change to reflect the scenario of this new symbol

-          None of the issues happens in the backtest, meaning that the issue happens when interacting with the broker, which is something that makes the fixing more difficult, also because the issues are not consistent

 

Why ALL issues happen:

When the buy signal is open, EA sends the order, but sometimes, this order does not get processed because:

·         Something is wrong in the broker for that particular Symbol

·         There is no more volume available at that price

All this will lead the order to stay in a “Placed” status. The big problem is that EA only checks if there is no position open for a Symbol, before sending a new order for that Symbol. This is expected, to have only one position open for each Symbol.

By not checking these placed positions, if the signal stays open, EA will keep sending orders, causing a big risk to the user if the case is that of opening a position. If the case if trying to close a position, the placed get there, never is processed and EA seems to “forget” about that position, never closing it, even after the Max time is reached

 

1)       Bug find/fix: automatically identify and exclude orders in the “placed” status

Sometimes, the buy/sell signal opens, the order is sent, but the order remains in the “placed” status, causing a lot of issues later. This happens in rare occasions, usually when the symbol “freezes” for some reason, right when the signal opens.

These placed positions might also be the reason why the EA malfunction regarding an open position, not closing for any of the “close triggers”

The expect solution (open to suggestion) is to constantly look for this status and remove them (on tick)

Also, in order to avoid more issues, if a symbol is on placed status, check and do not send other orders for the same symbol while this situation is not changed.


 

2)       Bug find/fix: understand why sometimes the position opens with double volume and solve it

The volume to fill the order is calculated based on the lot size defined in the parameter. Example: If the lot size = $10k and price of the stock is $35, the EA should try to buy 10k/35 volume, or 285 units. Then the lower next multiple of 100 need to be select, in this case 200.

In this market, all order must be in multiples of 100 (100, 200, 300, etc). This is controlled by the Lot_Min parameter.

Must of the time, this process works well, and the right volume is sent as an order, but in 1% of the cases, the order is sent with double the volume. There is apparently no relation to a specific symbol or price

After many testing, it seems that when the order takes time to be processed, EA sends another order (because the signal still open) and when broker manages to process the order, it process both of them.

 

3)       Force EA to close positions after the Max time is reached

It seems that when above issues (previously explained) happen, that particular Symbol are not monitored anymore for SL,TP and Time limit. Apparently that symbol might be getting out of the EA array that checks the open positions.

Closing a position after X minutes, should not be linked to anything else, for safety purposes, any position open more than X minutes should be closed

 

How to test the Fixes:

Backtest can be used to check basic keyl aspects of the code, but only in Single Symbol mode.

As mentioned before, these issues only happen in real accounts in live mode, since the issue is related to the interaction with the broker

Once the project starts I will share user/password to an demo account with the correct broker that will allow you to better test the EA


ファイル:

応答済み

1
開発者 1
評価
(12)
プロジェクト
12
25%
仲裁
1
0% / 100%
期限切れ
0
2
開発者 2
評価
(41)
プロジェクト
46
28%
仲裁
9
0% / 100%
期限切れ
7
15%
3
開発者 3
評価
(26)
プロジェクト
34
26%
仲裁
7
14% / 43%
期限切れ
7
21%
4
開発者 4
評価
(344)
プロジェクト
363
71%
仲裁
4
100% / 0%
期限切れ
0
取り込み中
5
開発者 5
評価
(21)
プロジェクト
24
17%
仲裁
15
20% / 40%
期限切れ
6
25%
類似した注文
Hi there, I would like an EA based of this indicator in the MQL store located here https://www.mql5.com/en/market/product/110504?source=Site +Profile+Seller#description MACD Signal Indicator by Adam Zolei I would like all the settings to be configurable in the original indicator, with a few extra such as Time Fiter e.g. only trade between these 2 time periods also I want an option to change the candle signal, e.g. if
I need a developer of the robot that shall do the following 1. Makes a minimum of $600 per month with a capital of $60 2. The robot shall be plug and pay (In short it shall analyze the market and execute trades) 3. The robot should be compatible to MT5 Mobile Phone and computer MT5. 4. The robot shall allow me to set date of expiry to any account of broker. The robot shall trade the Market Structure Cheat Codes which
Hi, I have my own strategy and some development done on it. But my developer is not able to solve few errors. Strategy has been built already. Can anyone help me with that
We are looking for an experienced MQL5 programmer to develop an Expert Advisor (EA) on MetaTrader 5. The project involves creating an automated trading bot that uses a methodology based on the integration of 2 technical indicators. If you have proven experience in similar projects, we invite you to apply. Main Description of the Bot Trading Methodology Details : The trading bot will operate based on a strategy that
Build mql5 EA and connection to python file , need mql5 and python skills , need to be able to know how connect MT5 EA to python file and have had experience doing it before. PLEASE no-one respond to this job request if you do NOT have very good experience doing this type of thing. My time and money has already been wasted with other devs (not devs from mql5.com) So please do not apply if you do not have very good
1. **Daily Opening Price:** - On MT15, use a horizontal line to mark the daily opening price. 2. **Key Levels:** - Calculate key levels by adding 90 points to the opening price. For example, if the opening price is 1800.12, the key levels will be: - +90 points: 1890.12 - +180 points: 1980.12 - +270 points: 2070.12 - +360 points: 2160.12 - For levels below the opening price, subtract 90 points: -
Job Title: Expert Advisor (EA) Developer for Forex Trading Job Description: I am seeking an experienced Expert Advisor (EA) developer to create a customized trading bot for the MetaTrader 4/5 platform. The bot will be designed to execute a sophisticated trading strategy that incorporates daily range calculations, cost averaging, and hedging with precise pip management. The successful candidate should have strong
Hello, I have built and EA with FX Dreema ( https://fxdreema.com/ ) that uses the maximum and minimum vales of the previous candle to entry on a trade. After that, I put a Stop Loss and Trailing Stop on that order, and goes as the market follows up and down. First, I recognize what I'm asking in this project may not be possible. I know about the differences in results comparing Strategy Tester with Real and Live
I have an indicator here for sun Candlesticks...I'm looking for a programmer who can convert it to an EA . The EA must just follow the color of the candlesticks. Open and close based on the color of the candlesticks
Hello, I am looking to make a modification to an indicator so it runs NT8. This is the link to the indicator in question. https://ninjatraderecosystem.com/user-app-share-download/realtime-level-ii-tick-volume/ I also want to know if if will be possible to add drop down boxes so I can change / choose my own colours and halve an option to adjust the width of the side bar regards

プロジェクト情報

予算
50+ USD
開発者用
45 USD