CategoricalVector<T>.Compact Method

Compacts the vector's index to include only those values that are present in the vector.

Definition

Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
C#
public void Compact()

Remarks

A categorical vector contains a mapping of values and corresponding level indexes. If this mapping is not fixed, it is possible that it contains values that are no longer present in the vector. Calling this method ensures that the growth of the mapping is kept in check.

See Also