pub struct IrisDataset { /* private fields */ }Expand description
The Iris flower dataset
A classic dataset for classification containing measurements of 150 iris flowers from 3 species (setosa, versicolor, virginica).
Implementations§
Source§impl IrisDataset
impl IrisDataset
Sourcepub fn into_inner(self) -> ArrowDataset
pub fn into_inner(self) -> ArrowDataset
Get the underlying Arrow dataset
Sourcepub fn features(&self) -> Result<ArrowDataset>
pub fn features(&self) -> Result<ArrowDataset>
Get feature columns as a new dataset (excludes species)
§Errors
Returns an error if transform fails.
Sourcepub fn labels_numeric(&self) -> Vec<i32>
pub fn labels_numeric(&self) -> Vec<i32>
Get species labels as numeric (0=setosa, 1=versicolor, 2=virginica)
Trait Implementations§
Source§impl CanonicalDataset for IrisDataset
impl CanonicalDataset for IrisDataset
Source§fn data(&self) -> &ArrowDataset
fn data(&self) -> &ArrowDataset
Returns the full dataset
Source§fn num_features(&self) -> usize
fn num_features(&self) -> usize
Returns the number of features (excluding label)
Source§fn num_classes(&self) -> usize
fn num_classes(&self) -> usize
Returns the number of classes (for classification datasets)
Source§fn feature_names(&self) -> &'static [&'static str]
fn feature_names(&self) -> &'static [&'static str]
Returns the feature column names
Source§fn target_name(&self) -> &'static str
fn target_name(&self) -> &'static str
Returns the label/target column name
Source§fn description(&self) -> &'static str
fn description(&self) -> &'static str
Returns a description of the dataset
Source§impl Clone for IrisDataset
impl Clone for IrisDataset
Source§fn clone(&self) -> IrisDataset
fn clone(&self) -> IrisDataset
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for IrisDataset
impl !RefUnwindSafe for IrisDataset
impl Send for IrisDataset
impl Sync for IrisDataset
impl Unpin for IrisDataset
impl UnsafeUnpin for IrisDataset
impl !UnwindSafe for IrisDataset
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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 moreCreates a shared type from an unshared type.