how to assign values to NETCDF file?# Computation - 科学计算
r*e
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
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