Type Definition polars_core::datatypes::DurationChunked
source · pub type DurationChunked = Logical<DurationType, Int64Type>;
Available on crate feature
dtype-duration
only.Implementations§
source§impl DurationChunked
impl DurationChunked
pub fn time_unit(&self) -> TimeUnit
Available on crate features
temporal
or dtype-datetime
or dtype-date
only.sourcepub fn cast_time_unit(&self, tu: TimeUnit) -> Self
Available on crate features temporal
or dtype-datetime
or dtype-date
only.
pub fn cast_time_unit(&self, tu: TimeUnit) -> Self
temporal
or dtype-datetime
or dtype-date
only.Change the underlying TimeUnit
. And update the data accordingly.
sourcepub fn set_time_unit(&mut self, tu: TimeUnit)
Available on crate features temporal
or dtype-datetime
or dtype-date
only.
pub fn set_time_unit(&mut self, tu: TimeUnit)
temporal
or dtype-datetime
or dtype-date
only.Change the underlying TimeUnit
. This does not modify the data.
sourcepub fn from_duration<I: IntoIterator<Item = ChronoDuration>>(
name: &str,
v: I,
tu: TimeUnit
) -> Self
Available on crate features temporal
or dtype-datetime
or dtype-date
only.
pub fn from_duration<I: IntoIterator<Item = ChronoDuration>>(
name: &str,
v: I,
tu: TimeUnit
) -> Self
temporal
or dtype-datetime
or dtype-date
only.Construct a new DurationChunked
from an iterator over ChronoDuration
.
sourcepub fn from_duration_options<I: IntoIterator<Item = Option<ChronoDuration>>>(
name: &str,
v: I,
tu: TimeUnit
) -> Self
Available on crate features temporal
or dtype-datetime
or dtype-date
only.
pub fn from_duration_options<I: IntoIterator<Item = Option<ChronoDuration>>>(
name: &str,
v: I,
tu: TimeUnit
) -> Self
temporal
or dtype-datetime
or dtype-date
only.Construct a new DurationChunked
from an iterator over optional ChronoDuration
.
Trait Implementations§
source§impl IntoSeries for DurationChunked
impl IntoSeries for DurationChunked
source§impl LogicalType for DurationChunked
impl LogicalType for DurationChunked
source§fn get_any_value(&self, i: usize) -> PolarsResult<AnyValue<'_>>
fn get_any_value(&self, i: usize) -> PolarsResult<AnyValue<'_>>
Gets AnyValue from LogicalType