Hi Cathal:
ncdump will print out the netcdf header info and values in ascii. You might
find that you can parse it easy enough. ncdump -x will put out NcML but not the
data values.
The java library will put out NcML with the data values using:
java -classpath toolsUI.jar ucar.nc2.NCDumpW <NetCDF-3 filename> -ncml -vall
Unforunately, I just discovered that previous versions are not doing this
correctly, so you'll have to get the latest development release (4.0.25) from
http://www.unidata.ucar.edu/software/netcdf-java/. Note you should use NCDumpW
not NCDump as it says on the web page.
Cathal Browne wrote:
> Hi
>
> I am currently working on a project and I have been presented with a .nc
> file. I want a way of reading the data from this plainly. After some
> searching I found this site and the netcdf-java project. Looking through
> the archives I found suggestions that libraries here could convert a .nc
> file to xml format which would be ideal for me.
>
> The problem I am having now is any of the archives I have found that
> suggest this are dated few years back. The links in them either no
> longer exist or from the description in the archive and looking at the
> information on the linked page, the information and pages have
> drastically changed. So I'm a bit lost.
>
> Can any one suggest or point me in the direction of the up to date
> libraries for doing this or tell me if they even exist?
>
> Thanks
> Cathal browne
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> netcdf-java mailing list
> netcdf-java@xxxxxxxxxxxxxxxx
> For list information or to unsubscribe, visit:
> http://www.unidata.ucar.edu/mailing_lists/