⇐ ⇒

[CF-metadata] string valued coordinates

From: Jim Biard <jbiard>
Date: Thu, 30 Oct 2014 12:12:27 -0400

CF says that if the units attribute is missing, then the quantity has no
units.

The Conventions document, section 3.1 says:

The|units|attribute is required for all variables that represent
dimensional quantities (except for boundary variables defined
inSection 7.1, "Cell
Boundaries"<http://cfconventions.org/Data/cf-conventions/cf-conventions-1.6/build/cf-conventions.html#cell-boundaries>and
climatology variables defined inSection 7.4, "Climatological
Statistics"<http://cfconventions.org/Data/cf-conventions/cf-conventions-1.6/build/cf-conventions.html#climatological-statistics>).

and

Units are not required for dimensionless quantities. A variable with no
units attribute is assumed to be dimensionless. However, a units
attribute specifying a dimensionless unit may optionally be included.
The Udunits package defines a few dimensionless units, such as|percent|,
but is lacking commonly used units such as ppm (parts per million). This
convention does not support the addition of new dimensionless units that
are not udunits compatible. The conforming unit for quantities that
represent fractions, or parts of a whole, is "1". The conforming unit
for parts per million is "1e-6". Descriptive information about
dimensionless quantities, such as sea-ice concentration, cloud fraction,
probability, etc., should be given in
the|long_name|or|standard_name|attributes (see below) rather than
the|units|.

The unit of '1' is generally used to indicate fractions and the like. In
cases where I am storing a raw binary value, I leave off the units
attribute, as the 'number' isn't something that should be treated as a
decimal quantity.

Grace and peace,

Jim

On 10/30/14, 11:35 AM, John Caron wrote:
> My preference is that one explicitly puts in the units. For
> dimensionless, "1" or "" is ok for udunits. If the units attribute
> isnt there, I assume that the user forgot to specify it, so the units
> are unknown.
>
> Im not sure what CF actually says, but it would be good to clarify.
>
> John
>
> On Thu, Oct 30, 2014 at 2:37 AM, Hedley, Mark
> <mark.hedley at metoffice.gov.uk <mailto:mark.hedley at metoffice.gov.uk>>
> wrote:
>
> Hello CF
>
> > From: CF-metadata [cf-metadata-bounces at cgd.ucar.edu
> <mailto:cf-metadata-bounces at cgd.ucar.edu>] on behalf of Jonathan
> Gregory [j.m.gregory at reading.ac.uk <mailto:j.m.gregory at reading.ac.uk>]
>
> > Yes, there are some standard names which imply string values, as
> Karl says. If the standard_name table says 1, that means the
> quantity is dimensionless, so it's also fine to omit the units, as
> Jim says.
>
> I would like to raise question about this statement. Omitting the
> units and stating that the units are '1' are two very different
> things;
> dimensionless != no_unit
> is an important statement which should be clear to data consumers
> and producers.
>
> If the standard name table defines a canonical unit for a
> standard_name of '1' then I expect this quantity to be
> dimensionless, with a unit of '1' or some multiple there of.
> If the standard name states that the canonical unit for a
> standard_name is '' then I expect that quantity to have no unit
> stated.
> Any deviation from this behaviour is a break with the
> conventions. I have code which explicitly checks this for data sets.
>
> Are people aware of examples of the pattern of use described by
> Jonathan, such as a categorical quantities identified by a
> standard_name with a canonical unit of '1'?
>
> thank you
> mark
>
> _______________________________________________
> CF-metadata mailing list
> CF-metadata at cgd.ucar.edu <mailto:CF-metadata at cgd.ucar.edu>
> http://mailman.cgd.ucar.edu/mailman/listinfo/cf-metadata
>
>
>
>
> _______________________________________________
> CF-metadata mailing list
> CF-metadata at cgd.ucar.edu
> http://mailman.cgd.ucar.edu/mailman/listinfo/cf-metadata

-- 
CICS-NC <http://www.cicsnc.org/> Visit us on
Facebook <http://www.facebook.com/cicsnc> 	*Jim Biard*
*Research Scholar*
Cooperative Institute for Climate and Satellites NC <http://cicsnc.org/>
North Carolina State University <http://ncsu.edu/>
NOAA's National Climatic Data Center <http://ncdc.noaa.gov/>
151 Patton Ave, Asheville, NC 28801
e: jbiard at cicsnc.org
o: +1 828 271 4900
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.cgd.ucar.edu/pipermail/cf-metadata/attachments/20141030/42a7c2ce/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: iiagagce.png
Type: image/png
Size: 11847 bytes
Desc: not available
URL: <http://mailman.cgd.ucar.edu/pipermail/cf-metadata/attachments/20141030/42a7c2ce/attachment-0001.png>
Received on Thu Oct 30 2014 - 10:12:27 GMT

This archive was generated by hypermail 2.3.0 : Tue Sep 13 2022 - 23:02:42 BST

⇐ ⇒