Z- score of a multidimensional array

조회 수: 8 (최근 30일)
desert_scientist90
desert_scientist90 2019년 10월 23일
편집: Matt J 2019년 10월 23일
Hi I am new to matlab. I have a data set on a grid at 0.5 with x 141 y, 71 and x38. I am trying to get z scores for this multidimensional array. I used the code z=zscore(x) to get the z-scores which I got on the shape of 1*71*38. I want to end with a z-score per year instead of 2,698 values. Is there anyway I can get this?
Thanks in advance for your help.
  댓글 수: 1
Matt J
Matt J 2019년 10월 23일
편집: Matt J 2019년 10월 23일
If you started with an array of size 141x71x38, then zscore should have produced an array the same size,
>> X=rand(141,71,38);
>> Z=zscore(X);
>> whos X Z
Name Size Bytes Class Attributes
X 141x71x38 3043344 double
Z 141x71x38 3043344 double
I'm afraid I don't understand what your attachments mean either. matlab-z.mat contains what you got and yearz1.mat contains what you want to get? Why is year_z1 of dimensions 38x72 instead of 38x71? And which dimension of your arrays represent years?

댓글을 달려면 로그인하십시오.

답변 (0개)

Community Treasure Hunt

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

Start Hunting!

Translated by