[GRASS-user] Newbie adding additional modules?

Hamish hamish_nospam at yahoo.com
Tue Jun 27 00:20:03 EDT 2006


Barry Baker wrote:

> It has been nearly 16 years since I used Grass and now coming back.  
> I have GRASS up and running on my Mac PowerBook G4 with OS X 10.4.6

!!
 
> Now I am trying to install the r.out.netcdf module and am at a loss as
> to how to go about it.  Any help would be appreciated.

Unless r.out.netcdf is packaged for the new GRASS 6.1 Extension Manager
(GEM), and I'm pretty sure it isn't, you will need the full grass source
code to compile it.

after ./configure, make of source code,

mkdir raster/r.out.netcdf/
cd raster/r.out.netcdf/
cp r.out.netcdf_source_files/* .
make


alternatively and probably simpler, use r.out.gdal for NetCDF output:

GRASS> gdalinfo --formats
  GMT (rw): GMT NetCDF Grid Format
  netCDF (ro): network Common Data Format

In my old version of GDAL, the GMT version is only one which it can
write to. I'm not sure what the latest version can do.

http://www.gdal.org/formats_list.html

another indirect way is to use r.out.mat to make a Matlab array and
to save a NetCDF file from there. (r.out.mat is untested on big-endian
AFAIK, if that doesn't work use raw r.out.bin -> Matlab)

If you are looking to send output to GMT, there are other options &
scripts that can be used. see r.out.gmt on the wiki add-ons page and:
 http://169.237.35.250/~dylan/grass_user_group/#GMT_and_GRASS-overview



Hamish




More information about the grass-user mailing list