Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 433

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
It's as simple as that.
It's like this.
Alekseu Fedotov, Unfortunately, this is not it. You get the bar number with TF and then you use the same TF, but you need another one (this is the problem). We need to get the bar number with TF (for example 30) and then get the MA with TF (1440), starting from this bar with TF 30. It's like if you now (14.30) would like to get MA with TF 1440. Now - not a problem, but to transfer it to a couple of days ago, that is a problem.
Yes. We should use M1, and M5, .... - to check. Maybe use interpolation? mt5 has a tick history. If you let me know where the profit is, I will take another look.
I need to do the technical analysis retrospectively as if it were happening now and look at the result. That is as if I did technical analysis of MA with TF 1d at 14.30 yesterday and today I got the results of price movement by yesterday's MA. If I use TF 1440 today and look from yesterday's point of view, the data of technical analysis will be different, and therefore the results should be expected to be different.
Help, I need to draw a rectangle from the previous candle's high to a point 200p above it and time a bar ahead.
I wrote the code, but I don't understand why the left point of the rectangle doesn't move? The right one slides behind the hai.
Unexpected behaviour of the function... Earlier, when I tried to create an object named after an already existing one, an error was returned and the object did not change existing parameters into new ones. But now, apparently, changes were made and every time high[0] is changed or a new bar appears, high[1] already has a different value and one of the parameters changes when creating a new rectangle.
The way out is very simple: Check existence of the object before creating it.
It moves
No, I'm not drawing anything with this code
Look at my whole file.
Have a look at my file
Oh I see, you have MQL4 :)
Made arrays by timeseries and it worked, I still don't understand why it didn't work for me
With TF 1440 everything is clear. but with M1 as you wrote there is a big margin of error?
With TF 1440 everything is clear. but with M1 as you wrote big error?
I haven't tried it with M1, but I think the margin of error will be less. M1->M5 will be more accurate than M30-> 1d
Please advise on the answer to a specific question. I'm redoing the Bollinger.
Changed a couple of lines, doesn't draw bars. What is it, logarithms?
Volatility formula from https://research-journal.org/economical/analiz-razlichnyx-metodov-ocenki-istoricheskoj-volatilnosti-dlya-opcionnoj-torgovli/
Please tell me how to delete a graphical object. There are vertical lines whose names are constructed from variable values.
string name=="test1"; string Vertline="line_"+name; ObjectCreate(0,VertLine,OBJ_VLINE,0,time,cena); How can I delete only vertical lines with the name test1?