ODM2 / YODA-File

The YAML Observation Data Archive & exchange (YODA) File Format
BSD 3-Clause "New" or "Revised" License
4 stars 0 forks source link

Nested table syntax for data table? #2

Closed horsburgh closed 8 years ago

horsburgh commented 9 years ago

My original question: Are we keeping the nested table syntax for the data table? No existing tools will write files out this way (except perhaps for our Excel Template tool) because while it does parse, it isn't really standard YAML syntax. This is the whole – I want to open my YODA file in Excel discussion. Looks like using PyYAML they parse to exactly the same thing.

Anthony's response: Regarding the "I want to open my YODA file in Excel" discussion, I'm a firm believer that we should support this by recommending a convention for writing out each line the data table like this:

"2015-01-01 00:30:00",-7.0,-9.56,-9.31,-9.87,],[

rather than like this:

As Jeff points out, PyYAML parses both identically, so why not recommend the former to also ease the use of Excel? The only reason I can think of is that we may have a hard time writing out the former from PyYAML, and for those use cases, I think we should allow for both (but recommend the former, and set up the Excel Templates to output the former).

horsburgh commented 8 years ago

The new Time Series template adopts the following syntax for each line of data:

- [ "2015-01-01 00:30:00", -7.0, -9.56, -9.31, -9.87 ]

This is clean, it doesn't break across lines in the file, it doesn't require an open bracket at the end of the line, it parses in a standard way, and because it has both spaces and commas, it can easily be broken into columns in Excel using "text-to-columns" functionality with commas and spaces as delimiters.