public void increment(final double[] data)
throws DimensionMismatchException {
int length = data.length;
if (length != dimension) {
throw new DimensionMismatchException(length, dimension);
}
// only update the upper triangular part of the covariance matrix
// as only these parts are actually stored
for (int i = 0; i < length; i++){