Type Alias polars_core::datatypes::ObjectChunked
source · pub type ObjectChunked<T> = ChunkedArray<ObjectType<T>>;
Available on crate feature
object
only.Aliased Type§
struct ObjectChunked<T> { /* private fields */ }
Implementations§
source§impl<T> ObjectChunked<T>where
T: PolarsObject,
impl<T> ObjectChunked<T>where
T: PolarsObject,
source§impl<T> ObjectChunked<T>where
T: PolarsObject,
impl<T> ObjectChunked<T>where
T: PolarsObject,
sourcepub unsafe fn get_object_unchecked(
&self,
index: usize
) -> Option<&dyn PolarsObjectSafe>
pub unsafe fn get_object_unchecked( &self, index: usize ) -> Option<&dyn PolarsObjectSafe>
Get a hold to an object that can be formatted or downcasted via the Any trait.
§Safety
No bounds checks
sourcepub fn get_object(&self, index: usize) -> Option<&dyn PolarsObjectSafe>
pub fn get_object(&self, index: usize) -> Option<&dyn PolarsObjectSafe>
Get a hold to an object that can be formatted or downcasted via the Any trait.
Trait Implementations§
source§impl<T: PolarsObject> AggList for ObjectChunked<T>
Available on crate feature algorithm_group_by
only.
impl<T: PolarsObject> AggList for ObjectChunked<T>
Available on crate feature
algorithm_group_by
only.source§impl<T: PolarsObject> ChunkAggSeries for ObjectChunked<T>
impl<T: PolarsObject> ChunkAggSeries for ObjectChunked<T>
source§fn sum_reduce(&self) -> Scalar
fn sum_reduce(&self) -> Scalar
Get the sum of the
ChunkedArray
as a new Series
of length 1.source§fn max_reduce(&self) -> Scalar
fn max_reduce(&self) -> Scalar
Get the max of the
ChunkedArray
as a new Series
of length 1.source§fn min_reduce(&self) -> Scalar
fn min_reduce(&self) -> Scalar
Get the min of the
ChunkedArray
as a new Series
of length 1.source§fn prod_reduce(&self) -> Scalar
fn prod_reduce(&self) -> Scalar
Get the product of the
ChunkedArray
as a new Series
of length 1.source§impl<T: PolarsObject> ChunkAnyValue for ObjectChunked<T>
impl<T: PolarsObject> ChunkAnyValue for ObjectChunked<T>
source§unsafe fn get_any_value_unchecked(&self, index: usize) -> AnyValue<'_>
unsafe fn get_any_value_unchecked(&self, index: usize) -> AnyValue<'_>
Get a single value. Beware this is slow.
If you need to use this slightly performant, cast Categorical to UInt32 Read more
source§fn get_any_value(&self, index: usize) -> PolarsResult<AnyValue<'_>>
fn get_any_value(&self, index: usize) -> PolarsResult<AnyValue<'_>>
Get a single value. Beware this is slow.
source§impl<'a, T> ChunkApply<'a, &'a T> for ObjectChunked<T>where
T: PolarsObject,
impl<'a, T> ChunkApply<'a, &'a T> for ObjectChunked<T>where
T: PolarsObject,
type FuncRet = T
source§fn apply_values<F>(&'a self, f: F) -> Self
fn apply_values<F>(&'a self, f: F) -> Self
Apply a closure elementwise. This is fastest when the null check branching is more expensive
than the closure application. Often it is. Read more
source§impl<T: PolarsObject> ChunkExpandAtIndex<ObjectType<T>> for ObjectChunked<T>
impl<T: PolarsObject> ChunkExpandAtIndex<ObjectType<T>> for ObjectChunked<T>
source§fn new_from_index(&self, index: usize, length: usize) -> ObjectChunked<T>
fn new_from_index(&self, index: usize, length: usize) -> ObjectChunked<T>
Create a new ChunkedArray filled with values at that index.
source§impl<T> ChunkFilter<ObjectType<T>> for ObjectChunked<T>where
T: PolarsObject,
impl<T> ChunkFilter<ObjectType<T>> for ObjectChunked<T>where
T: PolarsObject,
source§fn filter(
&self,
filter: &BooleanChunked
) -> PolarsResult<ChunkedArray<ObjectType<T>>>where
Self: Sized,
fn filter(
&self,
filter: &BooleanChunked
) -> PolarsResult<ChunkedArray<ObjectType<T>>>where
Self: Sized,
Filter values in the ChunkedArray with a boolean mask. Read more
source§impl<T: PolarsObject> ChunkFull<T> for ObjectChunked<T>
impl<T: PolarsObject> ChunkFull<T> for ObjectChunked<T>
source§impl<T: PolarsObject> ChunkFullNull for ObjectChunked<T>
impl<T: PolarsObject> ChunkFullNull for ObjectChunked<T>
source§impl<T: PolarsObject> ChunkQuantile<Series> for ObjectChunked<T>
impl<T: PolarsObject> ChunkQuantile<Series> for ObjectChunked<T>
source§fn median(&self) -> Option<T>
fn median(&self) -> Option<T>
Returns the mean value in the array.
Returns
None
if the array is empty or only contains null values.source§fn quantile(
&self,
_quantile: f64,
_interpol: QuantileInterpolOptions
) -> PolarsResult<Option<T>>
fn quantile( &self, _quantile: f64, _interpol: QuantileInterpolOptions ) -> PolarsResult<Option<T>>
Aggregate a given quantile of the ChunkedArray.
Returns
None
if the array is empty or only contains null values.source§impl<T: PolarsObject> ChunkReverse for ObjectChunked<T>
impl<T: PolarsObject> ChunkReverse for ObjectChunked<T>
source§impl<T: PolarsObject> ChunkShift<ObjectType<T>> for ObjectChunked<T>
impl<T: PolarsObject> ChunkShift<ObjectType<T>> for ObjectChunked<T>
source§impl<T: PolarsObject> ChunkShiftFill<ObjectType<T>, Option<ObjectType<T>>> for ObjectChunked<T>
impl<T: PolarsObject> ChunkShiftFill<ObjectType<T>, Option<ObjectType<T>>> for ObjectChunked<T>
source§fn shift_and_fill(
&self,
_periods: i64,
_fill_value: Option<ObjectType<T>>
) -> ChunkedArray<ObjectType<T>>
fn shift_and_fill( &self, _periods: i64, _fill_value: Option<ObjectType<T>> ) -> ChunkedArray<ObjectType<T>>
Shift the values by a given period and fill the parts that will be empty due to this operation
with
fill_value
.source§impl<T: PolarsObject> ChunkUnique for ObjectChunked<T>
Available on crate feature algorithm_group_by
only.
impl<T: PolarsObject> ChunkUnique for ObjectChunked<T>
Available on crate feature
algorithm_group_by
only.source§fn unique(&self) -> PolarsResult<ChunkedArray<ObjectType<T>>>
fn unique(&self) -> PolarsResult<ChunkedArray<ObjectType<T>>>
Get unique values of a ChunkedArray
source§fn arg_unique(&self) -> PolarsResult<IdxCa>
fn arg_unique(&self) -> PolarsResult<IdxCa>
Get first index of the unique values in a
ChunkedArray
.
This Vec is sorted.source§fn n_unique(&self) -> PolarsResult<usize>
fn n_unique(&self) -> PolarsResult<usize>
Number of unique values in the
ChunkedArray
source§impl<T: PolarsObject> ChunkVar for ObjectChunked<T>
impl<T: PolarsObject> ChunkVar for ObjectChunked<T>
source§impl<T> Debug for ObjectChunked<T>where
T: PolarsObject,
impl<T> Debug for ObjectChunked<T>where
T: PolarsObject,
source§impl<T: PolarsObject> FromIterator<Option<T>> for ObjectChunked<T>
impl<T: PolarsObject> FromIterator<Option<T>> for ObjectChunked<T>
source§impl<T: PolarsObject> FromTrustedLenIterator<Option<T>> for ObjectChunked<T>
impl<T: PolarsObject> FromTrustedLenIterator<Option<T>> for ObjectChunked<T>
fn from_iter_trusted_length<I: IntoIterator<Item = Option<T>>>(iter: I) -> Self
source§impl<T> IntoGroupsProxy for ObjectChunked<T>where
T: PolarsObject,
Available on crate feature algorithm_group_by
only.
impl<T> IntoGroupsProxy for ObjectChunked<T>where
T: PolarsObject,
Available on crate feature
algorithm_group_by
only.source§fn group_tuples(
&self,
_multithreaded: bool,
sorted: bool
) -> PolarsResult<GroupsProxy>
fn group_tuples( &self, _multithreaded: bool, sorted: bool ) -> PolarsResult<GroupsProxy>
Create the tuples need for a group_by operation.
* The first value in the tuple is the first index of the group.
* The second value in the tuple is the indexes of the groups including the first value.
source§impl<'a, T> IntoIterator for &'a ObjectChunked<T>where
T: PolarsObject,
impl<'a, T> IntoIterator for &'a ObjectChunked<T>where
T: PolarsObject,
§type IntoIter = Box<dyn PolarsIterator<Item = <&'a ChunkedArray<ObjectType<T>> as IntoIterator>::Item> + 'a>
type IntoIter = Box<dyn PolarsIterator<Item = <&'a ChunkedArray<ObjectType<T>> as IntoIterator>::Item> + 'a>
Which kind of iterator are we turning this into?
source§impl<T: PolarsObject> NamedFrom<&[T], &[T]> for ObjectChunked<T>
impl<T: PolarsObject> NamedFrom<&[T], &[T]> for ObjectChunked<T>
source§impl<T: PolarsObject, S: AsRef<[Option<T>]>> NamedFrom<S, [Option<T>]> for ObjectChunked<T>
impl<T: PolarsObject, S: AsRef<[Option<T>]>> NamedFrom<S, [Option<T>]> for ObjectChunked<T>
source§impl<T> NewChunkedArray<ObjectType<T>, T> for ObjectChunked<T>where
T: PolarsObject,
impl<T> NewChunkedArray<ObjectType<T>, T> for ObjectChunked<T>where
T: PolarsObject,
source§fn from_iter_values(name: &str, it: impl Iterator<Item = T>) -> ObjectChunked<T>
fn from_iter_values(name: &str, it: impl Iterator<Item = T>) -> ObjectChunked<T>
Create a new ChunkedArray from an iterator.
fn from_slice(name: &str, v: &[T]) -> Self
fn from_slice_options(name: &str, opt_v: &[Option<T>]) -> Self
source§fn from_iter_options(
name: &str,
it: impl Iterator<Item = Option<T>>
) -> ObjectChunked<T>
fn from_iter_options( name: &str, it: impl Iterator<Item = Option<T>> ) -> ObjectChunked<T>
Create a new ChunkedArray from an iterator.
source§impl<T> VecHash for ObjectChunked<T>where
T: PolarsObject,
impl<T> VecHash for ObjectChunked<T>where
T: PolarsObject,
source§fn vec_hash(
&self,
random_state: RandomState,
buf: &mut Vec<u64>
) -> PolarsResult<()>
fn vec_hash( &self, random_state: RandomState, buf: &mut Vec<u64> ) -> PolarsResult<()>
Compute the hash for all values in the array. Read more