r**********e 发帖数: 28 | 1 I am just start to learn use netcdf file.
I am wondering if anyone know how to assign a data value to a variable in
netcdf file.
Here is my matlab program
self=netcdf('test.cdf','clobber'); % THIS IS TO OPEN A netcdf FILE
self.myGlobalAttribute =ncchar('test') % ASSIGN A GLOBAL ATTRIBUTE
self('myRecordDimension')=1 % DEDFINE RECORD DEMINSION
r = self('myRecordDimension')
self('myDimension') = 40 % DEFINE VARIABLE DIMENSION
d=self('myDimension')
self{'myVariable'} = nc | l***s 发帖数: 11 | 2
actually,I got acquainted with NETCDF using c/fortran77,
in http://www.unidat.ucar.edu
there are lot of information about netcdf,
current version of netcdf is 3.5.0 or 3.5.1 maybe,
of course,there are netcdf for fortran90 and java,or perl,python,ruby,a
nd matlab
in my opinion, you'd better to begin with c, it's most compact, very easy to
understand.
hope it would make any sense.
【在 r**********e 的大作中提到】 : I am just start to learn use netcdf file. : I am wondering if anyone know how to assign a data value to a variable in : netcdf file. : Here is my matlab program : self=netcdf('test.cdf','clobber'); % THIS IS TO OPEN A netcdf FILE : self.myGlobalAttribute =ncchar('test') % ASSIGN A GLOBAL ATTRIBUTE : self('myRecordDimension')=1 % DEDFINE RECORD DEMINSION : r = self('myRecordDimension') : self('myDimension') = 40 % DEFINE VARIABLE DIMENSION : d=self('myDimension')
|
|