How to time averaging a net.cdf file

조회 수: 2 (최근 30일)
Rascal07
Rascal07 2018년 4월 1일
I want to plot mean monthly chlorophyll from daily data. so far i can download the data for a single day and plot it as a pcolor using:
ncfile = 'dataset-global-nahindcast-bio-001-018-V5-chl_1521044729974.nc' ; % nc file name
% To get information about the nc file
ncinfo(ncfile)
% to display nc file
ncdisp(ncfile)
% to read a vriable 'var' exisiting in nc file
chlorophyll = ncread(ncfile,'CHL') ;
lat = ncread(ncfile,'latitude') ;
lon = ncread(ncfile,'longitude') ;
figure (1)
pcolor(lat,lon,chlorophyll)
shading interp
colormap hot
colorbar
grid on
which works when using a file which has data for a single day, but i would like to know how to average multiple days so that i can download larger files and plot mean monthly chlorophyll instead of daily chlorophyll. I have attached a file with info on the data structure. please let me know if anything else is needed.
Dimensions: [1×4 struct]
Variables: [1×7 struct]
Attributes: [1×15 struct]
Groups: []
Format: 'classic'
dimensions:
x = 143
y = 105
time_counter = 24
deptht = 1
Thanks in advance

답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by