polars_core::export::cast

Function primitive_to_boolean

Source
pub fn primitive_to_boolean<T>(
    from: &PrimitiveArray<T>,
    to_type: ArrowDataType,
) -> BooleanArray
where T: NativeType,
Expand description

Returns a BooleanArray where every element is different from zero. Validity is preserved.