pub struct Glm { /* private fields */ }Expand description
A design matrix (observations × regressors) and the regressor being tested.
Implementations§
Source§impl Glm
impl Glm
pub fn new(design: Array2<f64>, tested: usize) -> Result<Self, MethodError>
pub fn n_observations(&self) -> usize
pub fn degrees_of_freedom(&self) -> f64
Sourcepub fn t(&self, y: ArrayView2<'_, f64>) -> Array1<f64>
pub fn t(&self, y: ArrayView2<'_, f64>) -> Array1<f64>
t of the tested coefficient for each feature (column of y).
Sourcepub fn nuisance_residuals(&self, y: ArrayView2<'_, f64>) -> Array2<f64>
pub fn nuisance_residuals(&self, y: ArrayView2<'_, f64>) -> Array2<f64>
Residuals of each feature after the nuisance regressors (Freedman & Lane 1983).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Glm
impl RefUnwindSafe for Glm
impl Send for Glm
impl Sync for Glm
impl Unpin for Glm
impl UnwindSafe for Glm
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