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

NAME

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

KEYWORDS

10       raster, projection
11

SYNOPSIS

13       r.proj
14       r.proj help
15       r.proj   [-ln]     [input=name]     location=string     [mapset=string]
16       [dbase=string]     [output=name]    [method=string]    [memory=integer]
17       [resolution=float]   [--overwrite]  [--verbose]  [--quiet]
18
19   Flags:
20       -l
21           List raster maps in input location and exit
22
23       -n
24           Do not perform region cropping optimization
25
26       --overwrite
27           Allow output files to overwrite existing files
28
29       --verbose
30           Verbose module output
31
32       --quiet
33           Quiet module output
34
35   Parameters:
36       input=name
37           Name of input raster map to re-project
38
39       location=string
40           Location of input raster map
41
42       mapset=string
43           Mapset of input raster map
44
45       dbase=string
46           Path to GRASS database of input location
47
48       output=name
49           Name for output raster map (default: input)
50
51       method=string
52           Interpolation method to use
53           Options: nearest,bilinear,cubic
54           Default: nearest
55
56       memory=integer
57           Cache size (MiB)
58
59       resolution=float
60           Resolution of output map
61

DESCRIPTION

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

NOTES

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

REFERENCES

198       [1]  Evenden,  G.I.   (1990) Cartographic projection procedures for the
199       UNIX environment - a  user's  manual.   USGS  Open-File  Report  90-284
200       (OF90-284.pdf) See also there: Interim Report and 2nd Interim Report on
201       Release 4, Evenden 1994).
202
203       Richards, John  A.  (1993),  Remote  Sensing  Digital  Image  Analysis,
204       Springer-Verlag, Berlin, 2nd edition.
205
206       PROJ.4: Projection/datum support library.
207
208       Further reading
209
210                      ASPRS Grids and Datum
211
212                      Projections Transform List (PROJ.4)
213
214                      MapRef - The Collection of Map Projections and Reference
215                     Systems for Europe
216
217                      Information and Service System for  European  Coordinate
218                     Reference Systems - CRS
219

SEE ALSO

221         g.region,  g.proj,  g.setproj, i.rectify, r.support, r.stats, v.proj,
222       v.in.region
223
224       The 'gdalwarp' and 'gdal_translate' utilities are  available  from  the
225       GDAL project.
226

AUTHORS

228       Martin Schroeder, University of Heidelberg, Germany
229
230       Man  page text from S.J.D. Cox, AGCRC, CSIRO Exploration & Mining, Ned‐
231       lands, WA
232
233       Updated by Morten Hulden
234
235       Datum tranformation support and cleanup by Paul Kelly
236
237       Last changed: $Date: 2007-07-20 09:41:57 +0200 (Fri, 20 Jul 2007) $
238
239       Full index
240
241       © 2003-2008 GRASS Development Team
242
243
244
245GRASS 6.3.0                                                          r.proj(1)
Impressum