[ARCHIVE!] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Can't go anywhere without you - 4. - page 340
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
Yes, if you have ticked the "Skip useless results" box. Optimisation Results tab, right mouse button.
What should be the size of the arrays - I don't know. Its index should accumulate over the whole interval of calculated bars, i.e. starting from the bar limit.
I will try to describe the logic of the problem in words.
As long as the purpose of filling these arrays is not clear, no algorithm is born. It is not clear for what further purposes these arrays will be used. Hence there is no algorithm that is suitable for saving them. After all, they will be constantly overwritten with new data. You are talking about the length of the series. The green series will end as soon as the yellow or red series starts. Similarly, the red series will end as soon as the yellow or green series starts. In other words, only one series that is currently in effect and the series that precedes it will be up-to-date. Or there should be several such series, alternating between them.
In short - in peasant-labor terms: why do we need these arrays of series? How will it be represented graphically in the turkey, or what for?
HELLO!!!
Who would help to write an EA with functions
1 open time H and M
2 loss volume (lot) multiplier
3 lot volume
4 stop loss
5 take profit
only for Buy position
It seems to be simple but it does not work
As long as the purpose of filling these arrays is not clear, no algorithm can be created. It is not clear for what further purposes these arrays will be used. Hence there is no algorithm for saving them. After all, they will be constantly overwritten with new data. You are talking about the length of the series. The green series will end as soon as the yellow or red series starts. Similarly, the red series will end as soon as the yellow or green series starts. In other words, only one series that is currently in effect and the series that precedes it will be up-to-date. Or there should be several such series, alternating between them.
In short - in peasant-labor terms: why do we need these arrays of series? How will it be represented graphically in the turkey, or what for?
The code shows that there is a different array for each type of series (green or red).
Purpose: to collect statistical information for further analysis, both using MQL tools and Excel.
Simply put, the array should look something like this
RedSeries[0]=10; RedSeries[1]=11; RedSeries[2]=4 ...
GreenSeries[0]=6; GreenSeries[1]=8; GreenSeries[2]=10 ...
If it matters, the dynamics of colour change is as follows: green cannot change into red, nor can red change into green. That is, there is always yellow in between.
Please explain, if an order is found to close and needs to be closed, is there a need to list the parameters after the ticket?
Example: OrderClose(OrderTicket(),OrderLots(),Bid,30,Blue);
replace with OrderClose(OrderTicket(),NULL,NULL,NULL);
or to OrderClose(OrderTicket(),EMPTY,EMPTY,EMPTY);
Is it possible to write it even shorter to close, considering only the ticket?
Please explain, if an order is found to close and needs to be closed, is there a need to list the parameters after the ticket?
Example: OrderClose(OrderTicket(),OrderLots(),Bid,30,Blue);
replace with OrderClose(OrderTicket(),NULL,NULL,NULL);
or to OrderClose(OrderTicket(),EMPTY,EMPTY,EMPTY);
Is it possible to write it even shorter to close, considering only the ticket?
No. There is a concept of partial order closure. Therefore the parameters must be specified explicitly. Try to open an order with lot=1.5 on the demo, and then close that order with lot=1. You will see that if the order went into profit, you can close not the whole order, but only a part of the lots, allowing the remaining lots to continue going into profit.
The code shows that there is a different array for each type of series (green or red).
Purpose: to collect statistical information for further analysis, both using MQL tools and Excel.
Simply put, the array should look something like this
RedSeries[0]=10; RedSeries[1]=11; RedSeries[2]=4 ...
GreenSeries[0]=6; GreenSeries[1]=8; GreenSeries[2]=10 ...
If it matters, the dynamics of colour change is as follows: green cannot change into red, nor can red change into green. That is, there is always yellow in between.
Hi all.
How do I recognise orders opened by an EA from the same orders with an empty magik opened manually?
Hi all.
How do I recognize an order opened by an EA from a manually opened order with an empty magic?
In the order loop we should check the OrderMagicNumber operator like this:
So set up two two-dimensional arrays. One for the Green data and one for the Red data. In one dimension write the time, in the other the numeric value. As soon as the green data appears, increase the green array by 1 and write in the time and the value of the zero bar. Do the same for the red array. Then, after the data is accumulated in the arrays, you can process them as needed. Or write all data to the file from the Expert Advisor at once.
Thank you.
But I can't understand the point of creating a time measurement. After all, there are several bars in a series and their times are different. In this way, it is not possible to record the series.
And another thing: I can't understand where there is a logical error in my code. What is the reason why it doesn't work? Without it, any attempt to redo anything is useless.