Calculates the Average True Range (ATR) across the full window of data.
Steps:
Previous closes (length L).
Highs (length L).
Lows (length L).
Central model for averaging TR.
ATR value.
Calculates the Internal Bar Strength (IBS).
IBS = (close - low) / (high - low)
High of the bar.
Low of the bar.
Close of the bar.
IBS in [0, 1].
Calculates the final value and percentage return of an investment.
Uses buy-and-hold assumption:
Initial asset price.
Final asset price.
Amount invested at start.
[finalValue, percentReturn].
Calculates the True Range (TR).
TR is the maximum of:
Previous period close.
Current period high.
Current period low.
True Range value.
Single-value "other" indicators. Foundational measures such as True Range, ATR, ROI, and Internal Bar Strength.