Learn R Programming

rgr (version 1.1.15)

rng: Undertakes a Range Transformation on the Columns of a Matrix

Description

Function to undertake a range transformation on a data matrix in order that each column is scaled zero-one between the minimum and maximum values.

Usage

rng(xx)

Arguments

xx

a n by p matrix to be range transformed.

Value

x

a n by p matrix of range-transformed values.

See Also

remove.na

Examples

Run this code
# NOT RUN {
## Make test data available
data(sind)
sind.mat <- as.matrix(sind[, -c(1:3)])

## Undertake range transform
temp <- rng(sind.mat)
temp

## Clean-up
rm(sind.mat)
rm(temp)
# }

Run the code above in your browser using DataLab