normalize: Normalize a vector or matrix within a range.

Description Usage Arguments Value Author(s) Examples

View source: R/normalize.r

Description

Normalizes a vector or matrix values to spread between a minimum and maximum value. By default, it normalizes between zero and one.

Usage

1
normalize(x, low = 0, high = 1)

Arguments

x

A vector or matrix of numeric values.

low

The minimum value desired in the output data.

high

The maximum value desired in the output data.

Value

A vector or matrix of normalized values.

Author(s)

Grant Williamson

Examples

1
2
k=matrix(runif(20),4,5)
normalize(k)

ozjimbob/ecbtools documentation built on Jan. 18, 2021, 7:39 p.m.