% Purpose % writes spacial axis value to data file. % % Synopsis % mexeps('putaxis',varcode,axid,axcode,name,frmt,units,type,ax_val) % mexeps('putaxis',varcode,axid,axcode,name,frmt,units,type,ax_val,range) % % Description % It sets and writes out spacial axis value to data file. The variable % which the axis associated with is refered to by variable code, % varcode. The axis is refered to by a axis id number, axid: 1 for % x-axis, 2 for y-axis, 3 for z-axis; and by the axis code, axcode % (e.g. 500 for latitude, 502 for longitude). Input argument also % include axis name, format, units, type ('even' or 'uneven') and % axis value (ax_val). The last argument, range, is optional. When % it is not specified, all axis value will be written out; when it % is specified, it is a 1x2 array contains [lower upper] limits of % the axis value you want to write. The data type of axis value % written to netCDF file is float. % % Examples % Open a data file and write out spacial axis values. % % mexeps('openw','pointer.file'); % open pointer file % mexeps('setnextw','datafile.ctd'); % open data file % % lon = 156+0.2/60; %East % lat = 0.5/60; %North % depth = [0; 5; 10; 15; 20]; %depth % varcode = 20 %temperature % % mexeps('putaxis',varcode,1,502,'lon',' ','degree_east','even',lon); % mexeps('putaxis',varcode,2,500,'lat',' ','degree_north','even',lat); % mexeps('putaxis',varcode,3,3,'depth',' ','m','even',depth); % ... % % write time axis % % write variable value % ... % % See Also % putvar, puttaxis %