normalize: Matrix normalization
Description
Normalize matrix rows using given norm. Copied from text2vec package.
Usage
normalize(m, norm = c("l1", "l2", "none"))Arguments
- m
matrix (sparse or dense).
- norm
character the method used to normalize term vectors