[Qgis-user] Issues with Global Soil Data netCDFs in QGIS & GDAL

Michael Treglia mtreglia at gmail.com
Fri Jun 19 09:02:03 PDT 2015


Hi All,

I'm trying to work with the Global Soil Dataset for Earth System Modeling
(available at: http://globalchange.bnu.edu.cn/research/soilw) and having
mixed success with the netCDF files - wanted to get any thoughts from folks
here as I'm pretty new to working with this format, and running into some
issues.

I'm primarily working with the 8-layer files (which are split into two
4-band files each; each band represents a different horizon). I'm able to
load netCDFs of some layers (in particular 'gypsum', 'CaCO3', and 'Total
Carbon') without issue (using QGIS 2.8 - both import raster and via the
netCDF viewer plugin). And running gdalinfo from the command line returns
the metadata without issue.

However, I've also been trying to work with Sand, Silt, Clay, and Gravel
Content (as % by weight), and not having any success in QGIS - the netCDF
files aren't recognized by the netCDF viewer, and can't be pulled in via
'import raster'. Also,  gdalinfo returns the following error:

ERROR 4: `SAND1.nc' not recognised as a supported file format.

I am able to read these data using R - most simply, using the 'raster'
package (sample code below), and I can also get the info using ncdf and
ncdf4 packages:
library(raster)
brk <- brick("[file name.nc]", varname="[variablename]")
#Can plot using
plot(brk) #plots all 4 layers from netcdf
plot(brk[[1]]) #Plots only first layer from netcdf

But, I'm trying to do this in QGIS or via gdal utilities for speed  - R is
slow for this (may be ways to speed it up, but haven't toyed with it much).

I'd appreciate any ideas on what might be contributing to these issues -
thanks in advance for any input!

Mike
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20150619/63f3dd20/attachment.html>


More information about the Qgis-user mailing list