- All Implemented Interfaces:
- TermWeightNormalizer, CloneableSerializable, Serializable, Cloneable
public class UnitTermWeightNormalizer
- extends AbstractTermWeightNormalizer
Normalizes term weights to be a unit vector. It is the most common form of
- Justin Basilico
- See Also:
- Serialized Form
- Creates a new
public void normalizeWeights(Vector weights,
- Description copied from interface:
- Normalizes the given weight vector. Can make use of the supporting
information such as the term counts for the document, and the global
weights used to compute the weights (if any). However, it does not have
to use this information if it does not need to.
weights - The weights to normalize. Contains an input and should be modified
to create an output. Cannot be null.
counts - The term counts for the document to normalize. Cannot be null.
globalWeights - The global weights to use in to create the weights, if any. Can be