There are two sections to this document, one dealing with converting vector data (immediately below), and the other dealing with converting raster data, click here to jump to that.

Note: when I say GRASS here, I'm talking about the Corps of Engineers version (4.x) . Whether this stuff will work with data sets from the other flavors of GRASS is something I just don't know. (If I tried to learn another GIS package at this point, my head would explode.)

GRASS2ARC ... for converting GRASS vector data to ArcInfo.

Written by:
Andy Rowan, Center for Remote Sensing and Spatial Analysis, Rutgers University, New Brunswick, NJ USA (e-mail rowan AT crssa.rutgers.edu, http://www.crssa.rutgers.edu/people/rowan)

There are two AMLs here, and several unix shell/awk scripts. One AML (grass2arc) is for getting line features from grass to arc, using a DLG file. You have to run v.out.dlg in grass first, then run grass2arc. The other AML, grasspt2arc, gets the points (sites) from a grass vector map into ArcInfo, via the GENERATE command. Both also take care of attribute tables: they do build or clean, then they get the category information from the grass map and add it into the ArcInfo attribute tables.

The reason for the two separate AMLs is that GRASS has a bug in it. (Shocking, I know.) When GRASS creates a DLG file, it doesn't include points from the map as degenerate line records in the DLG the way it ought to, so they have to be gotten separately. (GRASS does, however, count the points when it writes the record count into the DLG header, which causes ArcInfo to be unhappy about reading the DLG, giving the dreaded "unexpected EOF" message. The dlgfix.sh script included here is designed to fix that problem.)

The shell scripts included here are for doing various little tasks and are called by the AMLs; you don't need to run them directly (although you can if you want, to do things more interactively).

You'll need to edit a couple of lines in each of the two AMLs, to specify the pathnames of the shell scripts ... the first few &setvar statements in each AML. Read the comments.

You probably won't need to edit the shell scripts at all, the stuff they use is pretty standard unix stuff and *should* work fine on pretty much any flavor of unix. If there are problems with them, it's most likely to just be with paths. (Let me know if there are others.)

Click here to download grass2arc.tar

GRASS2GRID ... For Converting GRASS Rasters to ArcInfo Grids

This is simply a set of two shell scripts to streamline the conversion process. The method documented in the ArcInfo reference material works, it's just a bit quirky ... you have to set environment variables before you start ArcInfo that specify the location of the grass data. BUT (last I checked, anyway), the ArcInfo IMAGEGRID command does not successfully convert the color table. So there's a shell script here that does that for you. It even handles the color ramps that grass sometimes puts in the color tables, converting each ramp to a series of single values. There is no processing required from within GRASS to do this conversion; the imagegrid command operates directly on the grass raster files. Click here to download grass2grid.tar