Problems with netcdf data coordinates

4325
3
10-09-2011 09:24 PM
AnnaUkkola
New Contributor
Hello,

I have created a netcdf file in matlab and am trying to display and process it in ArcMap. I need to overlay it with a shapefile that uses the GCS_WGS_1984 projection and has longitude ranging from -180 to 180. My original netcdf file had a longitude vector ranging from 0.25 to 359.75 so only the positive longitudes could be overlaid with the shapefile (see image attached, netcdf file in blue). I changed the longitude vector to the following format:

0.25
0.75
..
..
..
179.75
-179.75
..
..
..
-0.75
-0.25

I was hoping this would allow me to overlay the shapefile and the netcdf file, and also have the zero latitude (greenwich) in the middle instead of the pacific. The file I created displays fine in Panoply so it is not corrupted or have a faulty coordinate system. However, ArcMap only displays one data point when I open the file and the attribute table only has one line with information FID 0, Shape point,  Runoff 0. When I try to convert this netcdf file into a raster I get the following error: ERROR 000276: one or both dimensions have variable spacing in their coordinate values. This happens despite the fact that the longitude vector is spaced at regular 0.5 degree intervals and has 720 values just like the original vector.

I'm confused as to why ArcMap cannot read this file and have run out of ideas on how to overlay the two datasets. The latitude vector is clearly fine but I do not know how I should format longitude for ArcMap to understand it and display negative (western) longitudes in the left and positive (eastern) longitudes in the right. Any help would be greatly appreciated!
Tags (2)
0 Kudos
3 Replies
SimonWright
New Contributor II
Hi

Did you ever receive any help or even solve the problem with displaying netCDF data as I'm experiencing the same problem.



Best wishes, Simon.
0 Kudos
CatalinaSegura
New Contributor
Hi
Did you ever solve this problem I ma running in the same problem
Any help is greatly appreciated.  My netcdf displays fine in panoply but ArcMap can't import the data.

Catalina
0 Kudos
JessicaFayne
New Contributor
The variable spacing in the data is caused when every space within the raster is not assigned a value. Even no data areas need to be assigned no data in order for ARCMAP to read it. So ArcMap can read rasters and convert to NETCDF which it can use, but the dataset has to be complete. I struggled with this for a few days before trying something else. I used QGIS (sorry ESRI, it was necessary) to open the NETCDF without any problem. You can then save the NETCDF as a Geotiff and open it in ArcMap to do whatever other processing or visualization that is necessary.

Best of luck
0 Kudos