How To Get the New Candle Range + Average of ATR from the Range
-
Hi guys, can you help me to get the all New Candle Bar that is Formed from the Initial Range.
Example Logic:
Initial Range = Candle 1-10 Highest and Lowest < averageATR of that candle Range.
now, sometimes newly formed Candles wont break the range immediately so the candle Range will Increase right?
That is what I want to get, as long as the new candle bars is formed inside the range keep on getting its candle range.
then if a Latest Candle 1 breaks the range either high or low, I want to get the average ATR of all of the candles inside that range.
-
Just to make it clear, when you say 'average ATR of that candle range' you mean the average value of all individual ATR values of that range, not only the average of the highest and the lowest ATR values there. Is that correct?
-
@l-andorrà yes sir, all ATR Values of that Range before the breakout, not just the Highest and Lowest
-
@deathkid13 Then you will need a loop dong the calculation. Are you familiar with variables and loops?
-
@l-andorrà I do know loops but I do not understand how it works adding NewBars. I do know how to get averages tho. but for new bars no.
-
@deathkid13 Then you can use this loop here:
https://fxdreema.com/shared/rTWMuzFB
In my example the loop will calculate the average value for ATR from candles 1 to 10 in the past. The calculation will be done at the open of each new candle. You can change the value of 'range' variable if you need longer or shorter periods.