You can export point features to a netCDF file with the Feature to NetCDF tool. A field from the feature attribute table can be exported either as a netCDF variable or as a dimension. Usually, the fields storing unique identifiers of features, such as IDs of rainfall stations or values identifying different events such as date of a time series, are exported as dimensions. However, fields storing measurement values, such as wind speed, wind direction, rainfall, and so on, are exported as variables. When no field is specified as dimension, the default dimension RecordID is created for exporting feature attributes in a variable. RecordID represents the OID of a feature.
Longitude and latitude or x- and y-coordinate values are exported as separate coordinate variables and linked to a variable through the coordinates attribute. The z- and m-values of the input features are exported as variables specified by the Z Variable and M Variable parameters.
The tool always creates a new netCDF file or overwrites an existing one. It does not append to an existing netCDF file.
- Click the Analysis tab.
- Click Tools.
- Type "Feature to NetCDF" in the text box.
- Click Feature to NetCDF in the results list to open the tool.
- Type the name in the Input Features text box or click the browse button to navigate to the input features.
- Click the Fields to Variables drop-down arrow, check one or multiple fields from the list, then click Add.
Four special fields, Shape.X, Shape.Y, Shape.Z, and Shape.M, are available in the drop-down list. They can be used for exporting x-coordinates or longitude, y-coordinates or latitude, z-values, and m-values of input features, respectively.
- Type the variable name in Variable for the added field, or alternatively, leave the default.
- Type the units in Units for the added field, or alternatively, leave it empty.
- Repeat steps 7 and 8 for additional fields if there are any added in step 6.
- Type the name in the Output netCDF File, or alternatively, leave the default.
- Click the Fields to Dimensions drop-down arrow, check one or multiple fields from the list, and click Add. The field (or fields) added will be the dimension (or dimensions) of variables specified in the Fields to Variables parameter.
- Type the dimension name in Dimension for the added field, or alternatively, leave the default.
- Type the units in Units for the added field, or alternatively, leave it empty.
- Repeat steps 12, and 13 for additional fields if there are any added in step 11.
- Click Run.