Learn R Programming

DMTL (version 0.1.2)

norm01: Normalize vector in [0, 1]

Description

This function normalizes a given vector between 0 and 1.

Usage

norm01(x)

Arguments

x

Vector containing data.

Value

The normalized vector.

Examples

Run this code
# NOT RUN {
x <- rnorm(100, 0.2, 0.3)
x_norm <- norm01(x)
print(range(x_norm))

# }

Run the code above in your browser using DataLab