pub struct FittedLogisticRegression<F: Float, C: PartialOrd + Clone> { /* private fields */ }
Expand description
A fitted logistic regression which can make predictions
Implementations§
Source§impl<F: Float, C: PartialOrd + Clone> FittedLogisticRegression<F, C>
impl<F: Float, C: PartialOrd + Clone> FittedLogisticRegression<F, C>
Sourcepub fn set_threshold(self, threshold: F) -> FittedLogisticRegression<F, C>
pub fn set_threshold(self, threshold: F) -> FittedLogisticRegression<F, C>
Set the probability threshold for which the ‘positive’ class will be predicted. Defaults to 0.5.
pub fn intercept(&self) -> F
pub fn params(&self) -> &Array1<F>
Sourcepub fn labels(&self) -> &BinaryClassLabels<F, C>
pub fn labels(&self) -> &BinaryClassLabels<F, C>
Get the model positive and negative classes mapped to their corresponding problem input labels.
Trait Implementations§
Source§impl<F: Clone + Float, C: Clone + PartialOrd + Clone> Clone for FittedLogisticRegression<F, C>
impl<F: Clone + Float, C: Clone + PartialOrd + Clone> Clone for FittedLogisticRegression<F, C>
Source§fn clone(&self) -> FittedLogisticRegression<F, C>
fn clone(&self) -> FittedLogisticRegression<F, C>
Returns a copy 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 moreSource§impl<F: Debug + Float, C: Debug + PartialOrd + Clone> Debug for FittedLogisticRegression<F, C>
impl<F: Debug + Float, C: Debug + PartialOrd + Clone> Debug for FittedLogisticRegression<F, C>
Source§impl<F: PartialEq + Float, C: PartialEq + PartialOrd + Clone> PartialEq for FittedLogisticRegression<F, C>
impl<F: PartialEq + Float, C: PartialEq + PartialOrd + Clone> PartialEq for FittedLogisticRegression<F, C>
Source§fn eq(&self, other: &FittedLogisticRegression<F, C>) -> bool
fn eq(&self, other: &FittedLogisticRegression<F, C>) -> bool
Tests for
self
and other
values to be equal, and is used by ==
.Source§impl<C: PartialOrd + Clone + Default, F: Float, D: Data<Elem = F>> PredictInplace<ArrayBase<D, Dim<[usize; 2]>>, ArrayBase<OwnedRepr<C>, Dim<[usize; 1]>>> for FittedLogisticRegression<F, C>
impl<C: PartialOrd + Clone + Default, F: Float, D: Data<Elem = F>> PredictInplace<ArrayBase<D, Dim<[usize; 2]>>, ArrayBase<OwnedRepr<C>, Dim<[usize; 1]>>> for FittedLogisticRegression<F, C>
impl<F: Float, C: PartialOrd + Clone> StructuralPartialEq for FittedLogisticRegression<F, C>
Auto Trait Implementations§
impl<F, C> Freeze for FittedLogisticRegression<F, C>
impl<F, C> RefUnwindSafe for FittedLogisticRegression<F, C>where
F: RefUnwindSafe,
C: RefUnwindSafe,
impl<F, C> Send for FittedLogisticRegression<F, C>where
C: Send,
impl<F, C> Sync for FittedLogisticRegression<F, C>where
C: Sync,
impl<F, C> Unpin for FittedLogisticRegression<F, C>where
C: Unpin,
impl<F, C> UnwindSafe for FittedLogisticRegression<F, C>
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> 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 more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<'a, F, R, T, S, O> Predict<&'a DatasetBase<R, T>, S> for Owhere
R: Records<Elem = F>,
O: PredictInplace<R, S>,
impl<'a, F, R, T, S, O> Predict<&'a DatasetBase<R, T>, S> for Owhere
R: Records<Elem = F>,
O: PredictInplace<R, S>,
§impl<F, D, E, T, O> Predict<ArrayBase<D, Dim<[usize; 2]>>, DatasetBase<ArrayBase<D, Dim<[usize; 2]>>, T>> for O
impl<F, D, E, T, O> Predict<ArrayBase<D, Dim<[usize; 2]>>, DatasetBase<ArrayBase<D, Dim<[usize; 2]>>, T>> for O
§impl<F, R, T, E, S, O> Predict<DatasetBase<R, T>, DatasetBase<R, S>> for Owhere
R: Records<Elem = F>,
S: AsTargets<Elem = E>,
O: PredictInplace<R, S>,
impl<F, R, T, E, S, O> Predict<DatasetBase<R, T>, DatasetBase<R, S>> for Owhere
R: Records<Elem = F>,
S: AsTargets<Elem = E>,
O: PredictInplace<R, S>,
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).§unsafe fn to_subset_unchecked(&self) -> SS
unsafe fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.