On Wed, Feb 22, 2017 at 11:38 AM, Bob Simons - NOAA Federal <
bob.simons at noaa.gov> wrote:
>
>> We need to either specify the "string" dimension, or have a consistent
>> convention:
>>
>> A 10x8 CHAR array could be either 10 8 character strings or 8 ten
>> character strings. And it gets more confusing with higher dimensions.
>>
>
> There is no standard naming system in CF to denote a String dimension (ie,
> the number of chars, vs a char array). That is a different approach to
> solving the problem. I don't like that approach as much because so many
> people have written so much software that writes and reads files using
> dimension names of their choice. I don't want to tell everyone to rewrite
> all their exiting files and software/scripts to read/write those files in
> order to comply with new CF rules.
>
> Instead, I'm proposing a separate, new attribute (data_type=string|char),
> partly because it doesn't interfere with existing dimension names or
> attribute names.
>
I wasn't clear -- even if you know a CHAR array is supposed to be an array
of strings, you don't know which dimension is the "string" dimension, and
which is the array dimension. If you have a 3x4 array of length-5 strings,
what is your CHAR array dimension? either of these would make sense:
(3,4,5)
(5,3,4)
and
(3,5,4) would be possible, though a bit insane :-)
even worse, if you see a "string" array that has dimensions of (3,4,5) what
is that? and (3,4) array of length-5 strings? a (4,5) array or length 3
strings?
-CHB
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker at noaa.gov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.cgd.ucar.edu/pipermail/cf-metadata/attachments/20170227/f323c26a/attachment.html>
Received on Mon Feb 27 2017 - 17:58:34 GMT