[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

octcdf, a netcdf toolbox for octave

From: Alexander
Subject: octcdf, a netcdf toolbox for octave
Date: Sun, 23 Oct 2005 08:27:11 -0500

Hi all,
I have written a toolbox, octcdf,  for reading and creating netcdf files from
octave. The toolbox uses the same syntax than the matlab toolbox of Charles R.
Denham ( But 
the matlab toolbox, octcdf is not based on a mexcdf (or mexnc) gateway. The 
toolbox is written in C++ calling directly the netcdf library. It uses an 
syntax (subsref and subsasgn) to manipulate netcdf dimensions, variables and
attributes. A minimal example for using octcdf would be:

% create a netcdf file
nc = netcdf('','c');    
% define netcdf dimension "dim" of length 4
nc('dim') = 4;
% define a netcdf variable "var" of type double
nc{'var'} = ncdouble('dim');
% store [1 2 3 4] in netcdf variable var
nc{'var'}(:) = [1 2 3 4];
% close netcdf file

Any suggestions or comments are of course very appreciated. You can download the
toolbox at:



Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:
How to fund new projects:
Subscription information:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]