[−][src]Trait rstats::RStats
Required methods
fn amean(&self) -> Result<f64>
fn ameanstd(&self) -> Result<MStats>
fn awmean(&self) -> Result<f64>
fn awmeanstd(&self) -> Result<MStats>
Implementations on Foreign Types
impl RStats for Vec<i64>
[src]
fn amean(&self) -> Result<f64>
[src]
Arithmetic mean of an i64 slice
Example
use rstats::RStats; let v1 = vec![1_i64,2,3,4,5,6,7,8,9,10,11,12,13,14]; assert_eq!(v1.amean().unwrap(),7.5_f64);
fn ameanstd(&self) -> Result<MStats>
[src]
Arithmetic mean and standard deviation of an i64 slice
Example
use rstats::RStats; let v1 = vec![1_i64,2,3,4,5,6,7,8,9,10,11,12,13,14]; let res = v1.ameanstd().unwrap(); assert_eq!(res.mean,7.5_f64); assert_eq!(res.std,4.031128874149275_f64);
fn awmean(&self) -> Result<f64>
[src]
Linearly weighted arithmetic mean of an i64 slice.
Linearly descending weights from n down to one.
Time dependent data should be in the stack order - the last being the oldest.
Example
use rstats::RStats; let v1 = vec![1_i64,2,3,4,5,6,7,8,9,10,11,12,13,14]; assert_eq!(v1.awmean().unwrap(),5.333333333333333_f64);
fn awmeanstd(&self) -> Result<MStats>
[src]
Liearly weighted arithmetic mean and standard deviation of an i64 slice.
Linearly descending weights from n down to one.
Time dependent data should be in the stack order - the last being the oldest.
Example
use rstats::RStats; let v1 = vec![1_i64,2,3,4,5,6,7,8,9,10,11,12,13,14]; let res = v1.awmeanstd().unwrap(); assert_eq!(res.mean,5.333333333333333_f64); assert_eq!(res.std,3.39934634239519_f64);
impl RStats for Vec<f64>
[src]
fn amean(&self) -> Result<f64>
[src]
Arithmetic mean of an f64 slice
Example
use rstats::RStats; let v1 = vec![1_f64,2.,3.,4.,5.,6.,7.,8.,9.,10.,11.,12.,13.,14.]; assert_eq!(v1.amean().unwrap(),7.5_f64);
fn ameanstd(&self) -> Result<MStats>
[src]
Arithmetic mean and standard deviation of an f64 slice
Example
use rstats::RStats; let v1 = vec![1_f64,2.,3.,4.,5.,6.,7.,8.,9.,10.,11.,12.,13.,14.]; let res = v1.ameanstd().unwrap(); assert_eq!(res.mean,7.5_f64); assert_eq!(res.std,4.031128874149275_f64);
fn awmean(&self) -> Result<f64>
[src]
Linearly weighted arithmetic mean of an i64 slice.
Linearly descending weights from n down to one.
Time dependent data should be in the stack order - the last being the oldest.
Example
use rstats::RStats; let v1 = vec![1_f64,2.,3.,4.,5.,6.,7.,8.,9.,10.,11.,12.,13.,14.]; assert_eq!(v1.awmean().unwrap(),5.333333333333333_f64);
fn awmeanstd(&self) -> Result<MStats>
[src]
Liearly weighted arithmetic mean and standard deviation of an i64 slice.
Linearly descending weights from n down to one.
Time dependent data should be in the stack order - the last being the oldest.
Example
use rstats::RStats; let v1 = vec![1_f64,2.,3.,4.,5.,6.,7.,8.,9.,10.,11.,12.,13.,14.]; let res = v1.awmeanstd().unwrap(); assert_eq!(res.mean,5.333333333333333_f64); assert_eq!(res.std,3.39934634239519_f64);