inverse function of zscore?

14 views (last 30 days)
pietro
pietro on 7 Jun 2014
Commented: pietro on 7 Jun 2014
Hi all,
is there any inverse function of zscore?

Accepted Answer

li haitao
li haitao on 7 Jun 2014
Edited: li haitao on 7 Jun 2014
Give you an exmaple:
>> load('lawdata.mat')
>> [Z,gpamean,gpastdev] = zscore(gpa);
>> gpa2=Z*gpastdev+gpamean;
>> gpa2-gpa
ans =
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
So gpa2 is the same with gpa.
  1 Comment
pietro
pietro on 7 Jun 2014
Thanks to all, I supposed there was an embedded function I wanted to use to improve the code readability.

Sign in to comment.

More Answers (1)

Star Strider
Star Strider on 7 Jun 2014
To get x from Z knowing the mean (mu) and standard deviation (s):
x = Z*s + mu

Community Treasure Hunt

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

Start Hunting!