maxabsnormalizetransform

Normalizes test dataset using values computed on training data by 'maxAbsNormalize' function.

Syntax

X_normalized = maxabsnormalizetransform(parameters,X)

Inputs

X
Input data to be normalized.
Type: double
Dimension: vector | matrix
parameters
Struct containing max absolute of each column of training data. It is the output of 'maxAbsNormalize' function.
Type: double | integer
Dimension: struct

Outputs

X_normalized
Normalized input records.
Type: integer
Dimension: vector | matrix

Example

Usage of maxabsnormalizetransform

X = [1, -1, 2;
     2, 0, 0;
     0, 1, -1];
X_test = [-3 -1 4];
[X_scaled, parameters] = maxabsnormalize(X);
X_test_scaled = maxabsnormalizetransform(parameters, X_test);
> X_test_scaled
X_test_scaled = [Matrix] 1 x 3
-1.50000 -1.00000 2.00000