How to apply a zero mean scaling in another set ?

2 次查看(过去 30 天)
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) ?

回答(1 个)

David Young
David Young 2015-1-30
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;
?

类别

Help CenterFile Exchange 中查找有关 Deep Learning Toolbox 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by