Difference between revisions of "CF Coordinate Conventions"

From Earth Science Information Partners (ESIP)
Line 7: Line 7:
 
|History=The convention was designed by Brian Eaton, Jonathan Gregory, Bob Drach, Karl Taylor and Steve Hankin. [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.0/cf-conventions.html Version 1.0, 28 October, 2003], [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.1/cf-conventions.html Version 1.1, 17 January, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.2/cf-conventions.html Version 1.2, 4 May, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.3/cf-conventions.html Version 1.3, 7 November, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.4/cf-conventions.html Version 1.4, 27 February, 2009]
 
|History=The convention was designed by Brian Eaton, Jonathan Gregory, Bob Drach, Karl Taylor and Steve Hankin. [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.0/cf-conventions.html Version 1.0, 28 October, 2003], [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.1/cf-conventions.html Version 1.1, 17 January, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.2/cf-conventions.html Version 1.2, 4 May, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.3/cf-conventions.html Version 1.3, 7 November, 2008] [http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.4/cf-conventions.html Version 1.4, 27 February, 2009]
 
}}
 
}}
 +
 +
=== Introduction ===
 +
 +
This is a short overview how netCDF-CF convention is written. It is not meant to be exhaustive, or replace the official documentation.
  
 
=== CF Metadata in the netCDF files ===
 
=== CF Metadata in the netCDF files ===
  
All the CF metadata is written in attributes. If variables names would have to be standard names, like '''nitrogen_monoxide''', it would limit the number of such variables to one per file. Therefore, to mark a variable, an attribute is used. The convention does not standardize any variable or dimension names.  
+
The convention does not standardize any variable or dimension names. All the CF metadata is written in attributes. If variable names would have to be standard names, like '''nitrogen_monoxide''', it would limit the number of such variables to one per file. Therefore, to name a variable to a standard name, an attribute is used.  
  
=== Description of the Data ===
+
Some important attributes:
==== Units ====
+
 
==== Long Name ====
+
* '''standard_name''' is the real name of the variable, from [[CF_Naming_Conventions|CF Naming Conventions]]
==== Standard Name ====
+
* '''long_name''' is the human readable, non-standard name.
==== Ancillary Data ====
+
* '''units''' is the human readable, non-standard name, from [http://www.unidata.ucar.edu/software/udunits/ udunits].
==== Flags ====
 
  
 
=== Coordinate Types ===
 
=== Coordinate Types ===
  
==== Latitude Coordinate====  
+
A coordinate variable is a variable that has only one dimension, and the name of the variable is the name of the dimension. The values in the variable are the dimension coordinates.
==== Longitude Coordinate====
+
 
 +
Four types of coordinates get special treatment in CF conventions, the three physical directions and time.
 +
 
 +
==== Latitude and Longitude Coordinate ====  
 +
 
 +
The latitude coordinate variable must have the same name as the latitude dimension
 +
 
 +
'''standard_name=latitude''' and optionally '''axis=Y''' marks the latitude variable. This can be used in projections that have an orthogonal latitude axis. Other projections must have '''axis=Y'''
 +
 
 +
Similarly, The longitude coordinate variable must have the same name as the longitude dimension and may have '''axis=X'''.
 +
 
 +
Coordinates of longitude axis typically are from -180...180 or 0..360, but that is not part of the convention.
 +
 
 
==== Vertical (Height or Depth) Coordinate ====  
 
==== Vertical (Height or Depth) Coordinate ====  
 +
 +
The ''''axis=Z''' attribute marks dimension either height or depth.
 +
 +
The direction of positive (i.e., the direction in which the coordinate values are increasing), whether up or down, cannot in all cases be inferred from the units. For example, if an oceanographic netCDF file encodes the depth of the surface as 0 and the depth of 1000 meters as 1000 then the axis would use attribute '''positive=down'''. If, on the other hand, the depth of 1000 meters were represented as -1000 then the value would be '''positive=up'''. For a pressure coordinates '''positive=down'''.
 +
 +
Vertical coordinate can also be dimensionless, like sigma_level.
 +
 
==== Time Coordinate ====  
 
==== Time Coordinate ====  
 +
 +
The variable is marked as '''standard_name=time''' and/or '''axis=T''' and '''units=hours since 1990-01-01"
 +
 +
 +
  
 
=== Coordinate Systems ===
 
=== Coordinate Systems ===

Revision as of 11:48, September 6, 2010

< Back to Glossary | Edit with Form

CF_Coordinate_Conventions Description: The purpose of the CF conventions is to create self-describing netCDF files: each variable in the file has an associated description of what it represents, each value can be located in space and time. An important benefit of a convention is that it enables software tools to display data and perform operations on specified subsets of the data with no user intervention. It is equally important that the metadata be easy for human users to write and to understand.

Glossary Domain: WCS, HTAP

Related Links

Links to this page
[[Links::CF Conventions, Standardized Geographic Region Names

Contributors

[[Contributors::Brian Eaton, Jonathan Gregory, Bob Drach, Karl Taylor, Steve Hankin, John Caron, Rich Signell, Phil Bentley, Greg Rappa, CFpeople.]]

History

[[History::The convention was designed by Brian Eaton, Jonathan Gregory, Bob Drach, Karl Taylor and Steve Hankin. Version 1.0, 28 October, 2003, Version 1.1, 17 January, 2008 Version 1.2, 4 May, 2008 Version 1.3, 7 November, 2008 Version 1.4, 27 February, 2009]]

Term Details


Introduction

This is a short overview how netCDF-CF convention is written. It is not meant to be exhaustive, or replace the official documentation.

CF Metadata in the netCDF files

The convention does not standardize any variable or dimension names. All the CF metadata is written in attributes. If variable names would have to be standard names, like nitrogen_monoxide, it would limit the number of such variables to one per file. Therefore, to name a variable to a standard name, an attribute is used.

Some important attributes:

  • standard_name is the real name of the variable, from CF Naming Conventions
  • long_name is the human readable, non-standard name.
  • units is the human readable, non-standard name, from udunits.

Coordinate Types

A coordinate variable is a variable that has only one dimension, and the name of the variable is the name of the dimension. The values in the variable are the dimension coordinates.

Four types of coordinates get special treatment in CF conventions, the three physical directions and time.

Latitude and Longitude Coordinate

The latitude coordinate variable must have the same name as the latitude dimension

standard_name=latitude and optionally axis=Y marks the latitude variable. This can be used in projections that have an orthogonal latitude axis. Other projections must have axis=Y

Similarly, The longitude coordinate variable must have the same name as the longitude dimension and may have axis=X.

Coordinates of longitude axis typically are from -180...180 or 0..360, but that is not part of the convention.

Vertical (Height or Depth) Coordinate

The 'axis=Z attribute marks dimension either height or depth.

The direction of positive (i.e., the direction in which the coordinate values are increasing), whether up or down, cannot in all cases be inferred from the units. For example, if an oceanographic netCDF file encodes the depth of the surface as 0 and the depth of 1000 meters as 1000 then the axis would use attribute positive=down. If, on the other hand, the depth of 1000 meters were represented as -1000 then the value would be positive=up. For a pressure coordinates positive=down.

Vertical coordinate can also be dimensionless, like sigma_level.

Time Coordinate

The variable is marked as standard_name=time and/or axis=T and units=hours since 1990-01-01"



Coordinate Systems

Independent Latitude, Longitude, Vertical, and Time Axes

Two-Dimensional Latitude, Longitude, Coordinate Variables

Reduced Horizontal Grid

Timeseries of Station Data

Trajectories

Grid Mappings and ProjectionsHorizontal Coordinate Reference Systems, Grid Mappings, and Projections

Scalar Coordinate Variables

Labels and Alternative Coordinates

Labels

Alternative Coordinates

Data Representative of Cells

Cell Boundaries

Cell Measures

Cell Methods

Climatological Statistics

Reduction of Dataset Size

Packed Data

Compression by Gathering