Normalize / Standardize / Scale the data to the fixed range from 0 to 1. The minimum value of data gets transformed into 0. The maximum value gets transformed into 1. Other values get transformed into decimals between 0 and 1.
Arguments
- x
A numeric vector to be scaled.
- y
An optional numeric vector used to determine the scaling range. If not provided, the scaling range is determined by the values in
x
. Default:y
=x
.