It looks like you're new here. If you want to get involved, click one of these buttons!
.Net API client
.Net / VBA / Excel (3rd party)
Algorithms and Strategies
Mobile and Desktop apps
Market data (WebSockets)
In this Discussion
Calculating the ATR and TR for DI (Directional Indicator)
I got the formula to calculate the TR i.e.
TR=max[(high−low) , abs(high−close(prev)), abs(low−close(prev))];
Now according to the requirement; we need to calculate ATR for last 14 days.
From the API we can get the OHLC value; but how can we get previous "close" value; for the current date and for last 14 days.
Please Guide asap !! Its urgent