pub struct DistributionFitting;Expand description
Distribution fitting utilities
Implementations§
Source§impl DistributionFitting
impl DistributionFitting
Sourcepub fn fit_normal(data: &Array1<f64>) -> Result<(f64, f64), UtilsError>
pub fn fit_normal(data: &Array1<f64>) -> Result<(f64, f64), UtilsError>
Fit normal distribution parameters
Sourcepub fn fit_exponential(data: &Array1<f64>) -> Result<f64, UtilsError>
pub fn fit_exponential(data: &Array1<f64>) -> Result<f64, UtilsError>
Fit exponential distribution parameter
Sourcepub fn fit_uniform(data: &Array1<f64>) -> Result<(f64, f64), UtilsError>
pub fn fit_uniform(data: &Array1<f64>) -> Result<(f64, f64), UtilsError>
Fit uniform distribution parameters
Sourcepub fn goodness_of_fit_test(
data: &Array1<f64>,
expected_cdf: fn(f64, &[f64]) -> f64,
parameters: &[f64],
bins: usize,
alpha: f64,
) -> Result<TestResult, UtilsError>
pub fn goodness_of_fit_test( data: &Array1<f64>, expected_cdf: fn(f64, &[f64]) -> f64, parameters: &[f64], bins: usize, alpha: f64, ) -> Result<TestResult, UtilsError>
Goodness of fit test using chi-square
Auto Trait Implementations§
impl Freeze for DistributionFitting
impl RefUnwindSafe for DistributionFitting
impl Send for DistributionFitting
impl Sync for DistributionFitting
impl Unpin for DistributionFitting
impl UnwindSafe for DistributionFitting
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