[Kst] NetCDF: plotting scalar components of time dependent 2D variables (vectors)

Rix, Patrick Patrick.Rix at repower.de
Fri Mar 8 13:31:00 UTC 2013


(..post resent without attachment to appear on the mailing list)

Dear Nicolas,

I'd like to add another whish concerning the NetCDF format (..if it's not already supported by KST and I just didn't realize it):

Would it be possible to implement support for plotting single (scalar) _components_ of time dependent 2D-variables like vectors by letting the user specify which component to plot over time, e.g. by giving the component's index similar to the ASCII interface when loading tabulated text data into KST, where each column becomes a data set.

I attached a ZIP-achive with some test data of a helical trajectory (e.g. of a particle) to illustrate what I mean.
The archive contains two binary *.nc files and their corresponding ncdump-ed *.cdf text files as well as a *.txt file with simple tabulated ascii data.

The file 'Helix_TestData_Vec3.nc' contains the data in a time dependent 2D-variable 'X_vector3(time, vec3)' with the dimensions 'time' and 'vec3', while
the file 'Helix_TestData_Scalar.nc' contains three scalar time dependent variables 'X_vector3_1(time)' , 'X_vector3_2(time)' and 'X_vector3_3(time)'.

KST correctly recognizes the scalar file while from the vector file only 'time' is noticed.

It would be nice if the second dimension of 2D-variables would be honoured by letting the user choose which index to plot.

I know doing this in general (e.g. N-dimensional data sets) quickly becomes complicated and time consuming, but at least for 2 dimensions (i.e. 'time' and some 'column-index') I guess it should be quite easy as the data structure looks like in a tabulated ascii file.
All that would be required is some sort of input field for the variable's column-index to be plotted.

More complex N-dimensional data structures like 3D or even 4D (i.e. time dep., gridded data e.g. like temperature values at different locations [given by latitude and longitude] and different heights as would be the case for meteorological data --> Temp(time,lat,long,height)) could be implemented later or handled by a work-around requiring some preprocessing, e.g. using the tool  'nc_explode'  which can split a multi-dimensional variable along a specified dimension.
See the 'ANTS' home page ('ARM-NetCDF Tool Suite') for more info & download:
<http://science.arm.gov/~cflynn/ANTS/index.html>.

The 2D-vector variable 'X_vector3' of file 'Helix_TestData_Vec3.nc' can be splitted into scalar vars using the command:

  nc_explode.exe  -vi X_vector3  -d vec3  -i Helix_TestData_Vec3.nc  -o Helix_TestData_Vec3_Xploded.nc

Under the link above several more tools for manipulating binary *.nc files can be found as well as under:
<http://www.arm.gov/data/tools> and <http://science.arm.gov/~cflynn/ARM_Tested_Tools/html/>


Have a nice weekend !

Cheers,
Patrick.

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte umgehend den Absender und löschen Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe der in dieser E-Mail enthaltenen Daten ist nicht gestattet. Wie Sie wissen, kann die Sicherheit von Übermittlungen per E-Mail nicht gewährleistet werden, E-Mails können missbräuchlich unter fremdem Namen erstellt oder verändert werden. Aus diesem Grund bitten wir um Verständnis dafür, dass wir zu Ihrem und unserem Schutz die rechtliche Verbindlichkeit der vorstehenden Erklärungen ausschließen müssen. Diese Regelung gilt nur dann nicht, wenn wir mit Ihnen eine anderweitige schriftliche Vereinbarung über die Einhaltung von Sicherheits- und Verschlüsselungsstandards getroffen haben.

This e-mail contains confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden. As you know, the security of e-mail transmissions can not be guaranteed. E-mails can be misused to be written or modified under false names. For that reason, we ask you to understand the necessity for us to rule out the legal obligation of the above statement, for your protection and ours. This regulation is only invalid if we have concluded a special written agreement with you about the compliance with security and encryption standards.

REpower Systems SE · Sitz: Hamburg · Vorstand: Andreas Nauen (Vorsitz), Matthias Schubert, Marcus A. Wassenberg, Vinod R. Tanti · Aufsichtsratsvorsitzender: Tulsi Tanti · Registergericht: AG Hamburg (Mitte) HRB Nr.: 118644


More information about the Kst mailing list