Function polars::export::arrow::compute::arithmetics::time::sub_duration_scalar
source · [−]pub fn sub_duration_scalar<T>(
time: &PrimitiveArray<T>,
duration: &PrimitiveScalar<i64>
) -> PrimitiveArray<T> where
T: NativeType + Sub<T, Output = T>,
f64: AsPrimitive<T>,
This is supported on crate feature
compute_arithmetics
only.Expand description
Subtract a duration to a time array (Timestamp, Time and Date). The timeunit enum is used to scale correctly both arrays; adding seconds with seconds, or milliseconds with milliseconds.