We just had a very similar discussion on vectors for the OOStethys project last week. It's a Pandora's box, but one that begs for a really reusable solution.
I found Jonathan's response not totally satisfying, for several reasons: the relationships seem to me not so much scientific as intrinsic; the ability to automate post-production, from netCDF files or other _self-contained_ metadata, in an interoperable way is becoming increasingly critical; and many people are *already* using the CF terms to determine what you can do with the data. (After all, what one can do with data is indicated most perfectly by what the data *is*; defining this is exactly the purpose of metadata.) But his suggestion is similar to a few of my own.
Re possible solutions I might suggest, for completeness I can imagine these approaches (sorry for duplication with past threads, perhaps someone can consolidate previous discussions if that's needed?):
- One term incorporates multiple values in a very constrained way.
- One term incorporates multiple values in a configurable (self-describing?) way
- The organization of CF terms is explicitly related (e.g., via an ontology)
In this case we know (for example) that _eastward and _northward terms are always the pairs of a vector; I think this is essentially the same as Jonathan's suggestion.
- Add the 'alias' concept, which may incorporate one or more of the above approaches (and has other uses).
- Add an overarching semantic convention, for example to allow explicitly associating other CF variables, as in
sea_water_velocity_vector->eastward_sea_water_velocity
sea_water_velocity_vector->northward_sea_water_velocity
In this case people that don't care about the association just skip past the '->' (or invert the order and they can stop reading when they get to the '<-'!).
Ideally the solution could apply to all specifications that will use the CF vocabulary (not just those that use the COARDS-CF format), since the vocabulary has developed a role beyond the content specification.
Partly due to this last point, i have a bias toward solutions that do not bind multiple values with only one name -- having a single name for every distinct component/value is appealing. (Just don't ask me about arrays....)
John
At 5:37 PM +0100 4/27/07, Jon Blower wrote:
>Thanks Jonathan.
>
>Here's a brief description of my use case. I have a collection of
>NetCDF files (ocean forecast and analysis) and I have written a Web
>Map Service that largely configures itself, based on the contents of
>the (CF) metadata in the files. I want to avoid, as far as possible,
>manual configuration of the server.
>
>Most variables (i.e. WMS layers) are scalar quantities, but I'd like
>my software to be able to automatically detect those layers that
>represent the components of a vector quantity. Then I can present,
>through the WMS, a new "virtual" layer that is rendered by default as
>vectors (arrows).
>
>As a particular example, many of the NetCDF files in question have
>component variables called "northward_sea_water_velocity" and
>"eastward_sea_water_velocity". I'd like to present these through the
>WMS as a single layer called "sea_water_velocity" that is rendered as
>a vector field.
>
>There are also examples that use magnitude and direction, e.g.
>"wind_from_direction" and "wind_speed".
>
>No doubt there will also be examples that give the components of the
>velocity along the grid unit vectors rather than "northward" and
>"eastward".
>
>I have only considered horizontal 2-D fields (for display on maps) but
>no doubt there will be cases where software will need to detect and
>display 3-D vector fields.
>
>Jon
>
>On 4/27/07, Jonathan Gregory <j.m.gregory at reading.ac.uk> wrote:
>> Dear Jon
>>
>> There is no way to do this at present in CF, but this is not the first time
>> the question has been asked. It could be done by introducing new standard
> > names which did not specify the component, and having a dimension running over
>> components, with values such as eastward, northward, x and y. I expect other
>> approaches are possible.
>>
>> It would be helpful if you could describe a particular use-case.
>>
>> Best wishes
>>
>> Jonathan
>>
>>
>>
>> > As you know, vector quanties such as velocities are often represented
>> > in CF-NetCDF as two separate component fields (e.g.
>> > "northward_sea_water_velocity" and "eastward_sea_water_velocity"). Is
>> > there a standard way in CF to represent vector quantities? E.g. in
>> > the above case could the two component fields be combined to give a
>> > single two-component variable called "horizontal_sea_water_velocity"
>> > or whatever the best standard name is? Is there any way to
>> > unambiguously represent the fact that two or more fields in a NetCDF
>> > file represent the components of a vector quantity (other than by
>> > interpreting the standard name)?
>> _______________________________________________
>> CF-metadata mailing list
>> CF-metadata at cgd.ucar.edu
>> http://www.cgd.ucar.edu/mailman/listinfo/cf-metadata
>>
>
>
>--
>--------------------------------------------------------------
>Dr Jon Blower Tel: +44 118 378 5213 (direct line)
>Technical Director Tel: +44 118 378 8741 (ESSC)
>Reading e-Science Centre Fax: +44 118 378 6413
>ESSC Email: jdb at mail.nerc-essc.ac.uk
>University of Reading
>3 Earley Gate
>Reading RG6 6AL, UK
>--------------------------------------------------------------
>_______________________________________________
>CF-metadata mailing list
>CF-metadata at cgd.ucar.edu
>http://www.cgd.ucar.edu/mailman/listinfo/cf-metadata
--
----------
John Graybeal <mailto:graybeal at mbari.org> -- 831-775-1956
Monterey Bay Aquarium Research Institute
Marine Metadata Initiative: http://marinemetadata.org || Shore Side Data System: http://www.mbari.org/ssds
Received on Fri Apr 27 2007 - 11:23:26 BST