Tarea técnica
I need an Expert Advisor (EA) programmed and designed to help me with trading. Requirements:
* The programmer must have experience in implementing software projects. * The script must be high-quality, clean, clear, and editable at any time, with ownership of the script provided.
* It must work on the MT4 platform. * The maximum project completion time is 7 to 14 days. * The programmer must be cooperative and flexible, providing support, addressing feedback, and modifying or adding conditions and commands.
The workflow should be as follows:
# A settings screen must be added, consisting of:
A. A field for the risk amount per trade.
B. A button to add a new trade.
C. A button to add a trade to a series.
D. A drop-down menu to track trade series, consisting of the following elements:
1. Series number.
2. Original trade size.
3. Trade type within the series (buy/sell) for each trade.
4. The result of trades within the series (profit/loss) for each trade, calculated as (amount + overnight cost). Likewise, the result of the entire series:
D - A button to close pending trades that have not yet been activated on the same currency pair only.
F - *************
# Now that the settings screen has been added, we move to the execution section.
1/ If a new trade is added from the settings:
2/ A new line called the "Activation Line" (blue) will appear on the trading screen. Move it on the screen and direct it to the desired location.
3/ Press the "Pin" button that appears at the end of the line.
4/ A new line called the "Balance Line" (red) will then automatically appear.
5/ You can then move the "Balance Line" on the screen to your desired location.
6/ The "Balance Line" is pinned using the "Pin" button at the end of the line.
Here, there are two possibilities:
A/ If the Balance Line is pinned above the execution line, the trade type is "Sell."
B/ If the Balance Line is pinned below the execution line, the trade type is "Buy."
7/ After pinning and specifying the trade type, the trade is ready to be activated.
8/ The trade is executed as soon as the price reaches the execution line, with a notification. Spread
9/ Also, after setting the balance line, a new line called the "Take Profit Line" (green) automatically appears. Note that this line is not a requirement for executing the trade. To activate the Take Profit Line, it must be set using the "Set" button.
10/ If the price reaches the balance line after the trade is executed, a new trade is opened with the opposite type of the original trade (e.g., if the original trade was a sell, the new trade will be a buy) and with the same size. The original trade should not be closed. This new trade does not have a stop-loss line or a balance line.
11/ In this case, we now have two trades: a buy trade and a sell trade, both of the same size. These two trades are linked together in a chain of trades. This link is accounted for, so the result of the linked trades appears in the window as a sum. This leads us to a new definition regarding these trades:
"Chain" is a group of trades linked to each other and to the original trade. They must be of the same contract size as the original trade, but the trade type does not have to be the same.
12/ Now, after the two trades are formed, the original trade... The second trade: If I later want to close one of the two trades manually or via the take-profit line, I can open a new trade using the same activation line for the still-active trade so that it remains in the same chain. Note that the new trade will not have a stop-loss line or a break-even line.
(End)
Notes:
1/ The settings interface and lines must be well-organized, with clean and consistent layout and calming colors.
2/ Any trade within the chain can be closed individually without affecting the remaining trades, even if it is the original trade. The result is recorded in the chain's total profits. If the original trade is closed individually, its status is transferred to the oldest trade in the chain, and subsequent trades are handled accordingly, such as linking trades to it.
3/ The lines must be dynamically and flexibly moved, and these lines should be generated by the Expert Advisor, not the platform, to ensure that trades are not affected by the bid-ask spread.
4/ All lines can be activated and deactivated using the "Confirm" button located at the end of each line. This applies before the trade is executed. After the trade is executed, it cannot be controlled, except for the take-profit line, which can be controlled both before and after the trade is activated.
This is before the trade is executed. 5/ The option to close the trade after activation via settings or a button at the end of the execution line.
6/ The pending order must be within the same Expert Advisor (EA) and not on the trading platform. Execution should be based solely on the bid price, ensuring the pending order is completely unaffected by the spread (the difference between the bid and ask prices).
7/ The EA must calculate the contract size based on the risk amount pre-set in the settings, taking into account the pip value for each pair. [Calculation Method: Risk Amount / (Stop Loss in Pip Value)]
8/ The function of the balance line is to calculate the contract size based on the distance between it and the execution line, along with the pip value for the pair. It also opens a reverse trade if the price reaches the line with the same size, without closing the original trade.
Note that this "balance line" does not appear in any other trades linked to the chain, but only in the original trades created initially. This is logical, as its primary purpose is to determine the location of the reverse trade and the contract size, which is only done in the first original trade of each chain.
9/ The trade information must be added to the execution line in the middle. The required information is as follows: A. Risk-to-reward ratio (e.g., 3:1)
B. Profit/loss amount of the transaction
C. Contract size
D.Transaction number recorded on the platform
F - Amount (Profit/Loss) Series