How to separate monthly data from yearly?

조회 수: 1 (최근 30일)
eko supriyadi
eko supriyadi 2018년 2월 14일
hello, everyone. I have a matrix of 15x18x213 size.
15 is longitude
18 is latitude, and
213 is time (month), the year start 2000-2017
my problem is.. how I can grab standard deviation for every month so I get new a matrix with size 15x18x12.
I'm tried with this code to looking for mean and work
%the code, work for mean
for k = 1:12
ind = month==k;
sst(:,:,k) = nanmean(data(:,:,ind),3);
end
%the code, not working
for k = 1:12
ind = month==k;
sst(:,:,k) = nanstd(data(:,:,ind),3);
end
I need an advance for it.. tks

답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by