Skip to main content

DataFrame

Struct DataFrame 

Source
pub struct DataFrame<FrameFields, FramedStore> { /* private fields */ }
Expand description

A data frame. A reference to the underlying data store along with record-based filtering and sorting details. FrameFields is a FieldLookupCons cons-list which maps a single label to one or more underlying store labels.

Implementations§

Source§

impl<FrameFields, FramedStore> DataFrame<FrameFields, FramedStore>
where FramedStore: NRows,

Source

pub fn len(&self) -> usize

Returns length (number of rows) in this DataFrame.

Source

pub fn is_empty(&self) -> bool

Returns whether or not this DataFrame is empty.

Trait Implementations§

Source§

impl<FrameIndex, FrameFields, FramedStore> AsFrameLookup<FrameIndex> for DataFrame<FrameFields, FramedStore>
where FrameFields: AsFrameLookup<FrameIndex>,

Source§

type Output = <FrameFields as AsFrameLookup<FrameIndex>>::Output

The computed FrameLookupCons.
Source§

impl<FrameFields, FramedStore> Clone for DataFrame<FrameFields, FramedStore>

Source§

fn clone(&self) -> DataFrame<FrameFields, FramedStore>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<FrameFields: Debug, FramedStore: Debug> Debug for DataFrame<FrameFields, FramedStore>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<FrameFields, FramedStore> FieldSelect for DataFrame<FrameFields, FramedStore>

Source§

fn field<Label>(&self) -> <Self as SelectFieldByLabel<Label>>::Output
where Self: SelectFieldByLabel<Label>,

Returns a struct containing the data for the field specified by Label. Read more
Source§

impl<StoreFields> From<DataStore<StoreFields>> for DataFrame<<StoreFields as SimpleFrameFields>::Fields, DataStore<StoreFields>>
where StoreFields: AssocStorage + SimpleFrameFields,

Source§

fn from( store: DataStore<StoreFields>, ) -> DataFrame<<StoreFields as SimpleFrameFields>::Fields, DataStore<StoreFields>>

Converts to this type from the input type.
Source§

impl<Labels, Frames> From<DataView<Labels, Frames>> for DataFrame<<Labels as SimpleFrameFields>::Fields, DataView<Labels, Frames>>
where Labels: SimpleFrameFields,

Source§

fn from( view: DataView<Labels, Frames>, ) -> DataFrame<<Labels as SimpleFrameFields>::Fields, DataView<Labels, Frames>>

Converts to this type from the input type.
Source§

impl<FrameFields, FramedStore> IntoView for DataFrame<FrameFields, FramedStore>
where FrameFields: AssocFrameLookup,

Source§

type Labels = <FrameFields as AssocFrameLookup>::Output

The Labels type parameter for the output DataView.
Source§

type Frames = Cons<Labeled<UTerm, DataFrame<FrameFields, FramedStore>>, Nil>

The Frames type parameter for the output DataView.
Source§

type Output = DataView<<DataFrame<FrameFields, FramedStore> as IntoView>::Labels, <DataFrame<FrameFields, FramedStore> as IntoView>::Frames>

The output DataView (should always be DataView<Self::Labels, Self::Frames>).
Source§

fn into_view(self) -> Self::Output

Convert self into a DataView object.
Source§

impl<FrameFields, FramedStore> NRows for DataFrame<FrameFields, FramedStore>
where FramedStore: NRows,

Source§

fn nrows(&self) -> usize

Return the number of rows in this data structure.
Source§

impl<FrameFields, FramedStore, Label> SelectFieldByLabel<Label> for DataFrame<FrameFields, FramedStore>
where FrameFields: SelectAndFrame<Label, FramedStore>,

Source§

type DType = <FrameFields as SelectAndFrame<Label, FramedStore>>::DType

Data type of accessed data.
Source§

type Output = Framed<<DataFrame<FrameFields, FramedStore> as SelectFieldByLabel<Label>>::DType, <FrameFields as SelectAndFrame<Label, FramedStore>>::Field>

The return type for the select_field method.
Source§

fn select_field(&self) -> Self::Output

Returns an object that provides DataIndex access to the data in the field specified by Label.
Source§

impl<FrameFields, FramedStore> SelfValued for DataFrame<FrameFields, FramedStore>

Allow DataFrames to be pulled from LVCons as Values

Source§

impl<FrameFields, FramedStore> UpdatePermutation for DataFrame<FrameFields, FramedStore>

Source§

fn update_permutation(self, new_permutation: &[usize]) -> Self

Consumes this object returns a new object with a permutation updated according to the provided indices.

Auto Trait Implementations§

§

impl<FrameFields, FramedStore> !Send for DataFrame<FrameFields, FramedStore>

§

impl<FrameFields, FramedStore> !Sync for DataFrame<FrameFields, FramedStore>

§

impl<FrameFields, FramedStore> Freeze for DataFrame<FrameFields, FramedStore>

§

impl<FrameFields, FramedStore> RefUnwindSafe for DataFrame<FrameFields, FramedStore>
where FrameFields: RefUnwindSafe, FramedStore: RefUnwindSafe,

§

impl<FrameFields, FramedStore> Unpin for DataFrame<FrameFields, FramedStore>
where FrameFields: Unpin,

§

impl<FrameFields, FramedStore> UnsafeUnpin for DataFrame<FrameFields, FramedStore>

§

impl<FrameFields, FramedStore> UnwindSafe for DataFrame<FrameFields, FramedStore>
where FrameFields: UnwindSafe, FramedStore: RefUnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<Frames> AssocDataIndexCons<Nil> for Frames

Source§

type Output = Nil

Type of associated data index cons-list.
Source§

fn assoc_data(&self) -> Nil

Returns the associated DataIndexCons.
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> HasLabels<Nil> for T

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> IntoLabeled for T

Source§

fn label<Label>(self) -> Labeled<Label, T>

Label this object with label Label.
Source§

impl<Frames, Store> JoinIntoStore<Nil, Store> for Frames

Source§

type Output = Store

The output type after augmenting Store.
Source§

fn join_into_store( &self, store: Store, _permutation: &[usize], ) -> Result<Store, AgnesError>

Augments store with data from self (as specified with Labels), using the provided permutation indices.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Valued for T
where T: SelfValued,

Source§

type Value = T

The associated value.
Source§

fn value_ref(&self) -> &T

Read-only reference to the value.
Source§

fn value_mut(&mut self) -> &mut T

Mutable reference to the value.
Source§

fn value(self) -> <T as Valued>::Value

Take ownership of the value.