polars_arrow::temporal_conversions

Function timeunit_scale

Source
pub fn timeunit_scale(a: TimeUnit, b: TimeUnit) -> f64
Expand description

Calculates the scale factor between two TimeUnits. The function returns the scale that should multiply the TimeUnit “b” to have the same time scale as the TimeUnit “a”.