Apprentice wrote:Have problem understand your specification.
For ADR
ADR: 100 (75%)
ADR is average of ( sum of all max-min) of N last days
As I understand it, it will be something like this...
We first calculate Day range
Day range will be High - Low price for the day
Average Day range will be average of the last N days
In brackets, you will have (Current Day range - Average Day range)/(Average Day range/100)
or is it
We first calculate Average Day range of all candles for current day
n brackets, you will have (Current candle range - Average Day range)/(Average Day range/100)
Hello dear friend apprentice, hope all is good. The first opton, I believe. I am not good at math. You wanna the calculation of the ADR to be based on the daily candle, not intraday candles. You only take in consideration the intraday candles in the case of the average daily movement calculation (the total up down movement). First you calculate the average range of N days. The ADR value is the average of last N days range (like ATR). What is inside the brackets is the room to move, how much of the average daily range the price has already filled. So it is important for the indicator to have the option to set the start time of the calculation (the 24h reset), given that different brokers have different start times for their daily candles (and server times).
For the weekly and monthly version of this indi to work properly then they have to be based on their respective timeframes (average weekly range based on weekly candles, average monthly range based on monthly candles). The average weekly and monthly movement can use the same calculation of the average daily movement, I guess.