[ARCHIVE]Any rookie question, so as not to clutter up the forum. Professionals, don't pass it by. Can't go anywhere without you - 5. - page 342
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
When you enter data do not uncheck the box "store personal information" in the window for username and password. All data are saved and you only need to select the account number (everything else is entered "automatically").
Thank you for your help, but you are trying to lead me down a road that you like or that you know, I am trying to find my way, my path. I ask you where south is, you answer, go north. I'm sorry, but I'm not going that way with you.
Terminal
F1
Service
Configuration at start-up
There is a stack of pending orders on both sides. If any of the pending orders are triggered, then on the other side the outermost pending order is deleted. In the screenshot I showed what happens if a buy order is triggered and the outermost short order is deleted.
I have done it if one position has triggered. But what if not one but 3 triggered at once? I.e., I should somehow estimate the number of triggered pending orders and close the pending orders of the opposite signal.
What is the best way to do it? Maybe, someone has already implemented this point? I have not decided to post this question to a separate branch. Perhaps, it will be very simple for those who understand this point better.
If we needed to delete only the lowest one position, we could find a position opened at the lowest price and delete it in the loop, but if there are several positions, what should we do? I would be glad to hear the opinion of those who already have experience with order grids.
Terminal
F1
Service
Configuration at startup
Just what I was looking for, thanks to the FAQ I should have started with :(
hoz, I think it is done this way: check for open trades and if there is more than 1, then close the rest
I have corrected my question and described the situation more precisely. You don't have to demolish everything, only the last orders!
And, again, we need to somehow record the fact that the next pending order has changed to a market order. I also do not quite understand how to do it.
I think I need to prescribe in icustom, I need to prescribe in icustom, but I can't do it.
Eugene, you have compiled files in zip, you need open source code to help you.
As for the standard zigzag , here is I.Kim's function.