pub struct CooksDistanceResult {
pub test_name: String,
pub distances: Vec<f64>,
pub p: usize,
pub mse: f64,
pub threshold_4_over_n: f64,
pub threshold_4_over_df: f64,
pub threshold_1: f64,
pub influential_4_over_n: Vec<usize>,
pub influential_4_over_df: Vec<usize>,
pub influential_1: Vec<usize>,
pub interpretation: String,
pub guidance: String,
}Expand description
Result of Cook’s distance analysis.
Cook’s distance measures how much each observation influences the regression model. Unlike hypothesis tests, this is an influence measure - not a test with p-values.
Fields§
§test_name: StringName of the test
distances: Vec<f64>Cook’s distance for each observation (one per observation)
p: usizeNumber of parameters (including intercept)
mse: f64Mean squared error of the model
threshold_4_over_n: f64Common threshold: 4/n (observations above this are potentially influential)
threshold_4_over_df: f64Conservative threshold: 4/(n-p-1)
threshold_1: f64Absolute threshold: D_i > 1 indicates high influence
influential_4_over_n: Vec<usize>Indices of observations exceeding 4/n threshold
influential_4_over_df: Vec<usize>Indices of observations exceeding conservative threshold
influential_1: Vec<usize>Indices of observations exceeding D_i > 1 threshold
interpretation: StringInterpretation of results
guidance: StringGuidance for handling influential observations
Trait Implementations§
Source§impl Clone for CooksDistanceResult
impl Clone for CooksDistanceResult
Source§fn clone(&self) -> CooksDistanceResult
fn clone(&self) -> CooksDistanceResult
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 moreSource§impl Debug for CooksDistanceResult
impl Debug for CooksDistanceResult
Auto Trait Implementations§
impl Freeze for CooksDistanceResult
impl RefUnwindSafe for CooksDistanceResult
impl Send for CooksDistanceResult
impl Sync for CooksDistanceResult
impl Unpin for CooksDistanceResult
impl UnwindSafe for CooksDistanceResult
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