
Contents |
NetCDF (NC)
Import netCDF file. It supports the file version not higher than 4.0.
1. fname$=RUC.nc; impNetCDF;
2. impNetCDF fname:="RUC.NC";
| Display Name | Variable Name | I/O and Type | Default Value | Description |
|---|---|---|---|---|
| File Name | fname |
Input string | |
Filename(s) of the file(s) to be imported. Click the browse button beside the list box to open one or more files and the filenames will be listed in the box. |
| File Info And Data Selection | trfiles |
Input TreeNode | |
This is used to select the desired data channels. See Description part of this document for details.
|
| Output | orng |
Output Range | |
Specifies the range for the imported data. See the syntax here. |
| Header Info | trheader |
Output TreeNode | |
This is for outputting the header information, which is hidden from the GUI. Users are not advised to use this variable.
|
| Import Filter | trFilter |
Input TreeNode | |
This is the TreeNode for the import filter, which is hidden from the GUI. Users are not advised to use this variable.
|
The Network Common Data Form (NetCDF) is a set of software libraries and data formats. These self-describing and machine-independent formats support the creation, access, and sharing of array-oriented scientific data. And it is platform independent.
This X-Function is used for importing NetCDF data files, whose version should be lower than 3.1. This X-Function supports multi-files importation. When a NetCDF file is imported, there will be at least one work book or one matrix book created. Workbooks are used to store one dimension datasets; while matrix books are used for storing datasets with two or more dimensions datasets. In the latter case, different dimensions of a dataset are saved in different channels in matrix sheets.
1. The following example imports an NetCDF(NC) data file with the dialog:
impNetCDF -d in command window. This will open the NetCDF dialog for you to choose the import file.
2. The following script command imports a NetCDF file (C:\Sample.NC) without opening the dialog:
fname$="C:\Sample.NC";
impNetCDF
3. The following example will use script to import all NetCDF files under a specific folder (assume it is C:\NetCDFData\).
cd C:\NetCDFData;
findFiles ext:="*.nc";
impNetCDF