Function calculate_trange
Source pub fn calculate_trange(df: &DataFrame) -> PolarsResult<Series>
Expand description
Calculates True Range (TRANGE)
True Range is the greatest of the following:
- Current High - Current Low
- |Current High - Previous Close|
- |Current Low - Previous Close|
§Arguments
df
- DataFrame containing the price data
§Returns
Returns a PolarsResult containing the True Range Series