pub struct CorrelationAnalysis;Expand description
Correlation analysis utilities
Implementations§
Source§impl CorrelationAnalysis
impl CorrelationAnalysis
Sourcepub fn pearson_correlation(
x: &Array1<f64>,
y: &Array1<f64>,
) -> Result<f64, UtilsError>
pub fn pearson_correlation( x: &Array1<f64>, y: &Array1<f64>, ) -> Result<f64, UtilsError>
Pearson correlation coefficient
Sourcepub fn spearman_correlation(
x: &Array1<f64>,
y: &Array1<f64>,
) -> Result<f64, UtilsError>
pub fn spearman_correlation( x: &Array1<f64>, y: &Array1<f64>, ) -> Result<f64, UtilsError>
Spearman rank correlation coefficient
Sourcepub fn kendall_tau(x: &Array1<f64>, y: &Array1<f64>) -> Result<f64, UtilsError>
pub fn kendall_tau(x: &Array1<f64>, y: &Array1<f64>) -> Result<f64, UtilsError>
Kendall’s tau correlation coefficient
Sourcepub fn correlation_matrix(data: &Array2<f64>) -> Result<Array2<f64>, UtilsError>
pub fn correlation_matrix(data: &Array2<f64>) -> Result<Array2<f64>, UtilsError>
Correlation matrix for multiple variables
Sourcepub fn correlation_test(
correlation: f64,
n: usize,
alpha: f64,
) -> Result<TestResult, UtilsError>
pub fn correlation_test( correlation: f64, n: usize, alpha: f64, ) -> Result<TestResult, UtilsError>
Test correlation significance
Auto Trait Implementations§
impl Freeze for CorrelationAnalysis
impl RefUnwindSafe for CorrelationAnalysis
impl Send for CorrelationAnalysis
impl Sync for CorrelationAnalysis
impl Unpin for CorrelationAnalysis
impl UnwindSafe for CorrelationAnalysis
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> 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