How to apply a zero mean scaling in another set ?

2 views (last 30 days)
I did a zero mean scaling:
x_mean = mean(input);
x_out=input-x_mean;
Scaling the output by maximum:
x_max = max(abs(x_out)); %Saving maximum values of each transformation.
x_out=x_out/x_max; %applying the maximum scaled.
How can I apply the scaling in another datset (like a test set) ?

Answers (1)

David Young
David Young on 30 Jan 2015
I'm not sure I understand the question, because the answer seems so simple, but assuming that input is a vector, so x_mean and x_max are scalars, do you just want
test_out = (test - x_mean) / x_max;
?

Categories

Find more on Deep Learning Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!