cov2.Rdcov2() is similar to cov() but has an additional argument. The denominator \(n\) (bias = TRUE) can be used (instead of \(n-1\)) to give a biased estimator of the (co)variance.
cov2(x, y = NULL, bias = TRUE)
| x | A numeric vector, matrix or data.frame. | 
|---|---|
| y | A numeric vector, matrix or data.frame. | 
| bias | A logical value. If bias = TRUE, \(n\) is used to give a biased estimator of the (co)variance. If bias = FALSE, \(n-1\) is used (default: TRUE). | 
Estimation of the variance (resp. covariance) of x (resp. x and y).