Learn R Programming

tspredit (version 1.2.747)

ts_norm_gminmax: Global Min–Max Normalization

Description

Rescale values so the global minimum maps to 0 and the global maximum maps to 1 over the training set.

Usage

ts_norm_gminmax(outliers = outliers_boxplot())

Value

A ts_norm_gminmax object.

Arguments

outliers

Indicate outliers transformation class. NULL can avoid outliers removal.

Details

The same scaling is applied to inputs and inverted on predictions via inverse_transform.

References

Ogasawara, E., Murta, L., Zimbrão, G., Mattoso, M. (2009). Neural networks cartridges for data mining on time series. Proceedings of the International Joint Conference on Neural Networks (IJCNN). doi:10.1109/IJCNN.2009.5178615

Examples

Run this code
# Global min–max normalization across the full training set
# Load package and example data
library(daltoolbox)
data(tsd)

# Build 10-lag windows and preview raw scale
ts <- ts_data(tsd$y, 10)
ts_head(ts, 3)
summary(ts[,10])

# Fit global min–max and transform; inspect post-scale values
preproc <- ts_norm_gminmax()
preproc <- fit(preproc, ts)
tst <- transform(preproc, ts)
ts_head(tst, 3)
summary(tst[,10])

Run the code above in your browser using DataLab