Skip to main content

sample_covariance

Function sample_covariance 

Source
pub fn sample_covariance(
    x: &[Complex<f64>],
    m: usize,
    forward_backward: bool,
) -> Result<Array2<Complex<f64>>, ErrorsJSL>
Expand description

Estimates the m × m covariance matrix of a time series from its overlapping length-m snapshots [x[i], …, x[i+m-1]]. With forward_backward the estimate is averaged with its conjugate-reversed counterpart, which decorrelates coherent sources and halves the variance.