fips.CovarianceMatrix.force_symmetry#
- CovarianceMatrix.force_symmetry(keep='lower')[source]#
Force the matrix to be perfectly symmetric by copying one triangle to the other.
Useful for eliminating floating-point asymmetry.
- Parameters:
keep ({'lower', 'upper'}, default 'lower') – Which triangle of the matrix to preserve and copy.
- Returns:
A new, perfectly symmetric covariance matrix.
- Return type: