/// <summary>Estimates.</summary>
/// <param name="X">The Matrix to process.</param>
/// <param name="type">(Optional) the type.</param>
public void Estimate(Matrix X, VectorType type = VectorType.Row)
{
int n = type == VectorType.Row ? X.Rows : X.Cols;
int s = type == VectorType.Row ? X.Cols : X.Rows;
Mu = X.Sum(type) / n;
Sigma = Matrix.Zeros(s);
for (int i = 0; i < n; i++)
{
var x = X[i, type] - Mu;
Sigma += x.Outer(x);
}
Sigma *= (1d / (n - 1d));
}