NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.
To learn about what's going on, see About the Archive Site.
http://nco.sf.net (Homepage, Mailing lists, Help) http://github.com/nco/nco (Source Code, Issues, Releases) What's new? Version 5.3.0 significantly improves the unpacking of ELM/CLM/CTSM history and restart datasets, and seems complete in this regard. ncrcat has more friendly behavior when appending, and ncclimo now outputs more metrics (such as valid area per gridcell) when in regional statistics mode. This release many be skipped if these changes do not interest you. Work on 5.3.1 is underway and includes improved NC_STRING support for autoconverting from netCDF4->netCDF3 for common workflows. Enjoy, Charlie NEW FEATURES (full details always in ChangeLog): A. Once again, ncks leveled-up how it unpacks ELM/CLM history/restart files. New features include automatic writing of fractional landunit and fractional column variables frc_landunit and frc_column, respectivly. frc_landunit is equivalent to the variable PCT_LANDUNIT sometimes placed in history files, but is expressed as a decimal fraction (not a percent) and is derived from restart files. The landunit dimension of frc_landunit is of size ten: Index zero contains the sum (should be 1.0) of standard landunit types/indexes 1-9 soil, crop, ..., urban medium density). frc_column is a bespoke version of the same, only for column (not landunit) types. For datasets with Multiple Elevation Classes (MECs): index = 0 is soil column, index = 1 is MEC == 1, indexes 2..10 are remaining MEC columns, index 11 is sub-total of MEC columns, index = 12 is deep lake column, index = 13 is wetland column, and index = 14 is grand total of natural columns. For non-MEC datasets, index = 0 is soil column, index = 1 is glaciated column, index = 2 is deep lake column, index = 3 is wetland column, and index = 4 is grand total of natural columns. ncks --s1d --hrz=history.nc restart.nc s1d_r05.nc # Restart file ncks -m -v frc.? s1d_r05.nc netcdf s1d_r05 { dimensions: column = 15 ; landunit = 10 ; lat = 360 ; lon = 720 ; variables: float frc_column(column,lat,lon) ; float frc_landunit(landunit,lat,lon) ; } http://nco.sf.net/nco.html#s1d http://nco.sf.net/nco.html#unpack_sparse B. ncks can now grid snow-related variables into a top-down (ocean-like) vertical grid that many think is more intuitive. By default ELM/CLM/CTSM store the negative of the number of active snow layers in the variable SNLSNO. Restart files for these models store the active snow layer butted-up against the lowest layers in the level dimension (so that they are continguous with soil layers to simplify hydrologic calculations). This makes snow variables in restart files hard to visualize. By default S1D now uses SNLSNO, if present, to unpack snow variables in a first layer downwards order, increasing with depth. Inactive layers at the bottom (i.e., where they reside physically). The resulting snow variables appear like ocean state variables over uneven bathymetry, with missing value underneath. We call this "snow-ocean" ordering to contrast it with the on-disk storage order of snow variables. http://nco.sf.net/nco.html#s1d http://nco.sf.net/nco.html#snw_ocn http://nco.sf.net/nco.html#snw_rdr http://nco.sf.net/nco.html#no_snw_ocn C. ncks S1D now accepts the "--rgr lut_out=$lut_out" option to specify which column type(s) to place in each gridcell in the output file. The argument lut_out is the standard landunit type of the column, with (thus far) two additional values that will output area-weighted averages of multiple landunit types: lut_out Output will be value of column(s) in this Landunit 1 Vegetated or bare soil 2 Crop 3 Landice (plain, no MEC) 4 Landice multiple elevation classes 5 Deep lake 6 Wetland 7 Urban tall building district 8 Urban high density 9 Urban medium density 10 Area-weighted average of all landunit types except MEC glaciers 13 Area-weighted average of soil+(non-MEC) glacier For example, ncks --s1d --rgr lut_out=1 --hrz=hst.nc rst.nc s1d.nc # Output Soil LUT ncks --s1d --rgr lut_out=13 --hrz=hst.nc rst.nc s1d.nc # Avg Soil+Glacier http://nco.sf.net/nco.html#s1d http://nco.sf.net/nco.html#lut_out D. ncremap always warns when it regrids land model files that contain a "landfrac" variable and SGS renormalization is not requested. This is because ELM/CLM/CTSM use "landfrac" for sub-gridscale fraction, and ignoring that causes errors along coastlines. EAMxx also archives that same "landfrac" but every EAMxx variable is valid throughout every gridcell so renormalization would be superfluous at best. Now ncremap no longer emits the "landfrac" WARNING for EAMxx files. http://nco.sf.net/nco.html#eamxx E. As of NCO version 5.3.0 (December, 2025) ncclimo automatically outputs additional metrics with global statistics. The output files containing the global timeseries also contain the variable valid_area_per_gridcell. This field is equivalent to the product of the area variable and the sgs_frc variable (if any). Thus for ELM/CLM/CTSM, this field equals area times landfrac, while for EAM/CAM this variable simply equals area. The output files also contain the area and sgs_frc variables separately. The presence of these variables in output allows downstream processors (e.g., zppy) to generate additional masks and weights for rescaling the statistics. For example, these fields can be used to rescale global sums into any units desired. ncclimo -P elm --split --rgn_stt=sum -c v3.LR.piControl -s 460 -e 461 \ --drc_in=drc_in --drc_out=drc_out http://nco.sf.net/nco.html#glb_stt http://nco.sf.net/nco.html#rgn_stt BUG FIXES: A. ncrcat ensures that the last time value and monotonicity are both defined before the monotonicity check is performed in REC_APN mode. This fixes overly noisy false-negative WARNINGs about monotonicity. Thanks to Seth McGinnis (NCAR) for reporting this problem. Full release statement at http://nco.sf.net/ANNOUNCE -- Charlie Zender, Dept. of Earth System Science University of California, Irvine 949-891-2429
netcdfgroup
archives: