.. highlightlang:: us .. _nc_dimdef: nc_dimdef ========= .. index:: nc_dimdef .. us.tag nc_dimdef ENGLISH NC_Dim :ref:`nc_dimdef` adds a new dimension to an open netCDF file. .. function:: dimid = nc_dimdef(ncid, ssName, nSize) .. us.return **Return Value** If the function succeeds, the return value is not equal to -1. If the function fails, the return value is -1. .. us.params **Parameters** .. uparam:: ncid Identifies the netCDF file. .. uparam:: ssName *ssName* is the name of the dimension. .. uparam:: nSize *nSize* is the size of the dimension. .. us.comment **Comment** The netCDF file must be in define mode. .. seealso:: :ref:`overview-netcdf-files`, :ref:`nc_create` :sub:`id-1793043`