Discussion of article "The checks a trading robot must pass before publication in the Market" - page 5

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
But then there's a chance of missing a deal.....
It's about the market. So there should be no errors. Or there should be their adequate processing.
If it wasn't for the market, I wouldn't have bothered much :)
I understand that the margin is for slippage?
If it wasn't for the market, I wouldn't have bothered much :)
I understand that the margin is for slippage?
Yes, in fact, to reduce the probability of making a mistake in case of sharp price movements a little bit more.
If it wasn't for the market, I wouldn't have bothered much :)
I understand that the margin is for slippage?
Slippage - at execution, and here - correctness of the trade request at the moment of the market environment state.
Calculated - checked correctness, corrected if necessary and sent the request. Then we checked the result of the request. This is on the EA side.
And execution is on the server side, and the slippage value is already required by the server part to accept or reject the request when the price changes.
Afternoon.
From the documentation:
SYMBOL_VOLUME_LIMIT.
The maximum allowed for this symbol is the total volume of an open position and pending orders in one direction (Buy or Sell). For example, if the limit is 5 lots, you can have an open Buy position with the volume of 5 lots and place a Sell Limit pending order with the volume of 5 lots. But you cannot place a Buy Limit pending order (because the total volume in one direction will exceed the limit) or place a Sell Limit order of more than 5 lots.
As far as I understand, the calculation should take into account the volume of all positions and orders only in the direction in which we are going to open a deal or place an order.
But here the Limitation on the number of lots for one symbol the direction is not taken into account at all....
Or have I misunderstood something?
Perhaps the lot should be normalised in this function so that there is no Disabled.
and then the function writes that there is no money, but it does not send a request to the server to open positions, which satisfies the rules of the market.
I have recently started to use such an instruction about 2 years ago:
Actually everything works.
When opening a trade, the Expert Advisor simply returns the Print("Not Enought Money Margin Required "+( string)margin) string;
The Expert Advisor is tested in the market, everyone is happy with it
Your variant is still working, unlike mine, which previously worked fine and this one, to which the validator directs us:
Thanks Vladislav!
Your variant is still working unlike mine, which worked fine before and this one, which the validator directs us to:
Where is this code shown?
PS I found it in the Portuguese and Japanese versions of the article and corrected it. There is also gdAfternoon.
From the documentation:
SYMBOL_VOLUME_LIMIT.
The maximum allowed for this symbol is the total volume of an open position and pending orders in one direction (Buy or Sell). For example, if the limit is 5 lots, you can have an open Buy position with the volume of 5 lots and place a Sell Limit pending order with the volume of 5 lots. However, you cannot place a Buy Limit pending order (because the total volume in one direction will exceed the limit) or place a Sell Limit order of more than 5 lots.
As far as I understand, the calculation should take into account the volume of all positions and orders only in the direction in which we are going to open a deal or place an order.
But here the Limitation on the number of lots for one symbol the direction is not taken into account at all....
Or have I misunderstood something?
You are right, in this example the direction is not taken into account. You can try to do it by taking into account the sign: Buy orders are taken positively, Sell - negatively. The value and sign on the output will give us the volume and direction.
We need to correct
Where is this code shown?
PS Found it in the Portuguese and Japanese versions of the article and corrected it. There is also gdI can't show it now, when I sent it for validation, in the report clicking on the 148 error I got to the
The version of the site was still in Russian.You are right, in this example the direction is not taken into account. We can try to do it by taking into account the sign: Buy orders are taken positively, Sell - negatively. The value and sign at the output will give us the volume and direction.
Need to be corrected
I don't understand about the sign...
I wrote this