Hi,
I'm using the r.in.gdal module to import ARCINFO GRID format raster files and I seem to be getting a shift in the extent of the data on import:
The files contain 1 by 1 degree resolution raster data. In Arc, the NS extent of the raster data is:
bottom edge of southernmost grid square = 90S
topmost edge of northernmost square = 77N
The raster therefore contains 167 rows of data.
When I import this, the file extent is as follows:
GRASS 5.0.0 > r.info temp
+----------------------------------------------------------------------------+
| Layer: temp Date: Fri Feb 28 10:14:32 2003 |
| Mapset: dorme Login of Creator: dorme |
| Location: global |
| DataBase: /Users/dorme/grass |
| Title: ( temp ) |
|----------------------------------------------------------------------------|
| |
| Type of Map: raster Number of Categories: 1 |
| Data Type: CELL |
| Rows: 167 |
| Columns: 557 |
| Total Cells: 93019 |
| Projection: UTM (zone 13) |
| N: 77.5 S: -89.5 Res: 1 |
| E: 330.5 W: -226.5 Res: 1 |
| Range of data: min = 0 max = 1 |
| |
| Data Source: |
| |
| |
| |
| Data Description: |
| generated by r.in.gdal |
| |
| |
+----------------------------------------------------------------------------+
The number of rows (and columns) are correct but the extent is peculiar - I'm guessing that r.info returns the centre points of the grid cells but if this is the case then the centre of the northernmost cell should be at 76.5N not 77.5N. This also makes the reported southern extent odd since the 89.5 S implies that there is still a gridsquare that has 90S as a bottom edge. Using d.where to inspect the location visually shows that the top of the northernmost cell in grass is now at 78N and the bottom of the lowermost cell is at 89S.
Something doesn't add up - I'm expecting to find that it may be me but can anyone clear this up?
System details:
Grass 5.0.0 running under Mac OSX (10.2.4) within Apple's X11 (v.2)
Many thanks,
David
----------------------------------------
Dr. David Orme
Department of Biological Sciences,
Imperial College London,
Silwood Park Campus,
Ascot, Berkshire.
SL5 7PY
Phone: +44 (0)20 759 42358
e-mail: d.orme@imperial.ac.uk