1r.proj(1)                     Grass User's Manual                    r.proj(1)
2
3
4

NAME

6       r.proj   -  Re-project  a  raster  map from one location to the current
7       location.
8

KEYWORDS

10       raster
11

SYNOPSIS

13       r.proj
14       r.proj help
15       r.proj    [-ln]    input=string    location=string      [mapset=string]
16       [dbase=string]    [output=name]    [method=string]   [resolution=float]
17       [--overwrite]
18
19   Flags:
20       -l  List raster files in input location and exit
21
22       -n  Do not perform region cropping optimization
23
24       --overwrite
25
26   Parameters:
27       input=string
28           Input raster map
29
30       location=string
31           Location of input map
32
33       mapset=string
34           Mapset of input map
35
36       dbase=string
37           Path to GRASS database of input location
38
39       output=name
40           Name for output raster map
41
42       method=string
43           Interpolation  method  to   use   Options:   nearest,bilinear,cubic
44           Default: nearest
45
46       resolution=float
47           Resolution of output map
48

DESCRIPTION

50       r.proj projects a raster map in a specified mapset of a specified loca‐
51       tion from the projection of the input location to a raster map  in  the
52       current  location. The projection information is taken from the current
53       PROJ_INFO files, as set with g.setproj
54        and viewed with g.proj.
55
56   Introduction
57       Map projections Map projections are a method of  representing  informa‐
58       tion from a curved surface (usually a spheroid) in two dimensions, typ‐
59       ically to allow indexing through cartesian coordinates.   There  are  a
60       wide  variety of projections, with common ones divided into a number of
61       classes,  including  cylindrical  and  pseudo-cylindrical,  conic   and
62       pseudo-conic,  and  azimuthal  methods, each of which may be conformal,
63       equal-area, or neither.
64
65       The particular projection chosen depends on the purpose of the project,
66       and the size, shape and location of the area of interest.  For example,
67       normal cylindrical projections are good for maps which are  of  greater
68       extent  east-west  than  north-south  and  in equatorial regions, while
69       conic projections are better in mid-latitudes;  transverse  cylindrical
70       projections  are  used for maps which are of greater extent north-south
71       than east-west; azimuthal  projections  are  used  for  polar  regions.
72       Oblique  versions  of any of these may also be used.  Conformal projec‐
73       tions preserve angular relationships, and better  preserve  arc-length,
74       while equal-area projections are more appropriate for statistical stud‐
75       ies and work in which the amount of material is important.
76
77       Projections are defined  by  precise  mathematical  relations,  so  the
78       method  of  projecting  coordinates  from  a geographic reference frame
79       (latitude-longitude) into a projected  cartesian  reference  frame  (eg
80       metres)  is  governed by these equations.  Inverse projections can also
81       be achieved.  The public-domain Unix software package proj [1] has been
82       designed  to  perform these transformations, and the user's manual con‐
83       tains a detailed description of over 100 useful projections.  This also
84       includes  a  programmers  library  of the projection methods to support
85       other software development.
86
87       Thus, converting a "vector" map - in which  objects  are  located  with
88       arbitrary  spatial precision - from one projection into another is usu‐
89       ally accomplished by a simple two-step process:  first the location  of
90       all  the  points  in  the  map are converted from the source through an
91       inverse projection into latitude-longitude, and then through a  forward
92       projection  into the target.  (Of course the procedure will be one-step
93       if either the source or target is in geographic coordinates.)
94
95       Converting a "raster map", or  image,  between  different  projections,
96       however,  involves  additional considerations.  A raster may be consid‐
97       ered to represent a sampling of a process at a regular, ordered set  of
98       locations.   The  set  of  locations that lie at the intersections of a
99       cartesian grid in one projection will not, in  general,  coincide  with
100       the  sample  points  in  another  projection.   Thus, the conversion of
101       raster maps involves an interpolation  step  in  which  the  values  of
102       points  at intermediate locations relative to the source grid are esti‐
103       mated.  Projecting vector maps within the GRASS GIS GIS  data  capture,
104       import  and transfer often requires a projection step, since the source
105       or client will frequently be in a different projection to  the  working
106       projection.
107
108       In  some  cases it is convenient to do the conversion outside the pack‐
109       age, prior to import or after export, using software  such  as  PROJ4's
110       cs2cs [1]. This is an easy method for converting an ASCII file contain‐
111       ing a list of coordinate points, since there is no topology to be  pre‐
112       served  and  cs2cs can be used to process simple lists using a one-line
113       command.
114
115       The format of vector files describing maps containing lines and arcs is
116       generally  more  complex, as parts of the data stored in the files will
117       describe topology, and not just coordinates.  In GRASS GIS  the  v.proj
118       module  is  provided  to reproject "vector" maps, transferring topology
119       and attributes as well as node coordinates.  This program uses the pro‐
120       jection definition and parameters which are stored in the PROJ_INFO and
121       PROJ_UNITS files in the PERMANENT  mapset  directory  for  every  GRASS
122       location.
123
124   Design of r.proj
125       As  discussed  briefly  above,  the fundamental step in re-projecting a
126       raster is resampling the source grid at locations corresponding to  the
127       intersections  of a grid in the target projection.  The basic procedure
128       for accomplishing this, therefore, is as follows:
129
130       r.proj converts a map to a new geographic projection. It  reads  a  map
131       from  a different location, projects it and write it out to the current
132       location.
133       The projected data is resampled with one of  three  different  methods:
134       nearest neighbor, bilinear and cubic convolution.
135
136       The nearest option, which performs a nearest neighbor assignment is the
137       fastest of the three resampling methods. It is primarily used for cate‐
138       gorical  data  such  as  a  land  use classification, since it will not
139       change the values of the data cells. The bilinear option determines the
140       new  value  of  the  cell based on a weighted distance average of the 4
141       surrounding cells in the input map. The cubic option determines the new
142       value  of  the cell based on a weighted distance average of the 16 sur‐
143       rounding cells in the input map.
144
145       The bilinear and cubic interpolation methods are most  appropriate  for
146       continuous  data  and  cause some smoothing. Both options should not be
147       used with categorical data, since the cell values will be altered.   If
148       nearest neighbor assignment is used, the output map has the same raster
149       format as the input map. If any of the both interpolations is used, the
150       output map is written as floating point.
151
152       Note that, following normal GRASS conventions, the coverage and resolu‐
153       tion of the resulting grid is set by the current region settings, which
154       may  be  adjusted using g.region.  The target raster will be relatively
155       unbiased for all cases if its grid has  a  similar  resolution  to  the
156       source, so that the resampling/interpolation step is only a local oper‐
157       ation.  If the resolution is changed significantly, then the  behaviour
158       of  the  generalisation  or  refinement will depend on the model of the
159       process being represented.  This will be very different for categorical
160       versus  numerical data.  Note that three methods for the local interpo‐
161       lation step are provided.
162
163       r.proj supports general datum transformations, making use of the PROJ.4
164       co-ordinate system translation library.
165

NOTES

167       To  avoid excessive time consumption when reprojecting a map the region
168       and resolution of the  target  location  should  be  set  appropriately
169       beforehand.   A simple way to do this is to generate a vector "box" map
170       of the region in the source location using v.in.region.  This "box" map
171       is  then  reprojected  into  the target location with v.proj.  Next the
172       region in the target location is set to the extent of  the  new  vector
173       map with g.region along with the desired raster resolution (g.region -m
174       can be used in Latitude/Longitude locations  to  measure  the  geodetic
175       length  of  a  pixel).   r.proj is then run for the raster map the user
176       wants to reproject.  In this case a little preparation goes a long way.
177
178       When reprojecting whole-world maps the user should disable map-trimming
179       with  the  -n  flag. Trimming is not useful here because the module has
180       the whole map in memory anyway. Besides that, world  "edges"  are  hard
181       (or impossible) to find in projections other than latitude-longitude so
182       results may be odd with trimming.
183

REFERENCES

185       [1] Evenden, G.I.  (1990) Cartographic projection  procedures  for  the
186       UNIX  environment  -  a  user's  manual.   USGS Open-File Report 90-284
187       (OF90-284.pdf) See also there: Interim Report and 2nd Interim Report on
188       Release 4, Evenden 1994).
189
190       Richards,  John  A.  (1993),  Remote  Sensing  Digital  Image Analysis,
191       Springer-Verlag, Berlin, 2nd edition.
192
193       PROJ 4: Projection/datum support library.
194
195       Further reading
196
197                      ASPRS Grids and Datum
198
199                      MapRef - The Collection of Map Projections and Reference
200                     Systems for Europe
201
202                      Projections Transform List (PROJ4)
203

SEE ALSO

205         g.region,  g.proj,  g.setproj, i.rectify, r.support, r.stats, v.proj,
206       v.in.region
207
208       The 'gdalwarp' and 'gdal_translate' utilities are  available  from  the
209       GDAL project.
210

AUTHORS

212       Martin Schroeder, University of Heidelberg, Germany
213
214       Man  page text from S.J.D. Cox, AGCRC, CSIRO Exploration & Mining, Ned‐
215       lands, WA
216
217       Updated by Morten Hulden
218
219       Datum tranformation support and cleanup by Paul Kelly
220
221       Last changed: $Date: 2006/05/02 14:09:18 $
222
223       Full index
224
225
226
227GRASS 6.2.2                                                          r.proj(1)
Impressum