Range Bar Chart on MT4 - page 48

 
thefxpros:
nothing, it is the EA you made for me when i asked to you if there was a way to invert the price of a symbol, insted of usdjpy i wanted jpyusd.

I change often the external variables values like range bars size and tf, bars number and nothing else.

Also the EA i had before shows the same issue. I just tried.

This is the previous EA. I attach also the ex4 because i don't know if it is new builds ready.

range_bars_ea.mq4

range_bars_ea.ex4

Than we can thank to metatrader

If nothing is changed in the code then there is only one obvious reason why is it happening : metatarader. And, frankly, I am sick of searching what the hell is going wrong with it

 
mladen:
Than we can thank to metatrader If nothing is changed in the code then there is only one obvious reason why is it happening : metatarader. And, frankly, I am sick of searching what the hell is going wrong with it

no, i found the problem. The issue occurs when i set "showgaps" on false. If i set it on true, the chart is created well.

before new builds i never used this features so i don't know if it is a bad writing code or metaquote sucks in any case.

 
thefxpros:
no, i found the problem. The issue occurs when i set "showgaps" on false. If i set it on true, the chart is created well. before new builds i never used this features so i don't know if it is a bad writing code or metaquote sucks in any case.

Strange

It should be the opposite

 

Are range bars repainting?

 
morro:
Are range bars repainting?

Yes. The same way as renko

 

what you're talking about?

Range and renko don't repaint at all. They do it only on metatrader when you close and restart it due its tick data lack.

 
thefxpros:
what you're talking about? Range and renko don't repaint at all. They do it only on metatrader when you close and restart it due its tick data lack.

renko and range bars repaint because you can not anchor them to one moment in time. Even if you could do that, your chart and your neighbors chart could be completely different if your anchor differed even as little as 1 tick. There is no non-repainting renko or range bar chart

PS: what you described in your post is a classical definition of repainting. Usually with indicators that is done by changing time frames back and forth but since you can not do that with renko and range bars, restarting is the equivalent of changing time frames or symbols

 
techmac:
renko and range bars repaint because you can not anchor them to one moment in time. Even if you could do that, your chart and your neighbors chart could be completely different if your anchor differed even as little as 1 tick. There is no non-repainting renko or range bar chart PS: what you described in your post is a classical definition of repainting. Usually with indicators that is done by changing time frames back and forth but since you can not do that with renko and range bars, restarting is the equivalent of changing time frames or symbols

I don't agree. Some range and renko bars generators have this anchor option and allow to start from a precise date in generating the chart. "completely different chart"? Maybe slightly differences that become completely negligible at the bar-size increase.

And i repeat that this issue is due to a metatrader lack, in other (serious) trading platforms, the chart is always the same, even if you restart the platform or change the bar size and then you come back at previous bar size.

Repaint is another thing.

Solution for metatrader? Just keep running the platform for a couple of weeks and you'll get some data to start visual backtesting in order to try a strategy.

 

The range bars chart does not need any anchor, it synchronizes on every reversal bar.

On the other hand, shape of the brick-based chart (Renko, Point Original) is sensitive to anchor level. With single feed there may be many different Renko charts, but only a single range bars chart.

And thefxpros is correct, the chart repaints with generator reset, when live chart gets replaced by a model.

 

use renko/rangebar on m1 and it will not repaint.

Reason: