Skip to main content

Module numeric

Module numeric 

Source
Expand description

Tolerance-based f64 comparison and the logarithmic-return transform. Numeric helpers owned by core.

Tolerance-based f64 comparison and the logarithmic-return transform over a Positive price series. Both are pure functions over core types with no layer above them in their signatures, so core owns them; market and simulation are callers, not owners.

Functionsยง

approx_equal
Checks for approximate equality between two f64 values within a defined tolerance.
calculate_log_returns
Calculate Logarithmic Returns