1r.random.surface(1) Grass User's Manual r.random.surface(1)
2
3
4
6 r.random.surface - Generates random surface(s) with spatial depen‐
7 dence.
8
10 raster
11
13 r.random.surface
14 r.random.surface help
15 r.random.surface [-uq] output=string[,string,...] [distance=float]
16 [exponent=float] [flat=float] [seed=integer] [high=integer]
17 [--overwrite] [--verbose] [--quiet]
18
19 Flags:
20 -u
21 Uniformly distributed cell values
22
23 -q
24 No (quiet) description during run
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 output=string[,string,...]
37 Names of the resulting maps
38
39 distance=float
40 Input value: max. distance of spatial correlation (value >= 0.0,
41 default [0.0])
42
43 exponent=float
44 Input value: distance decay exponent (value > 0.0), default [1.0])
45
46 flat=float
47 Input value: distance filter remains flat before beginning expo‐
48 nent, default [0.0]
49
50 seed=integer
51 Input value: random seed (SEED_MIN >= value >= SEED_MAX), default
52 [random]
53
54 high=integer
55 Input value: maximum cell value of distribution, default [255]
56
58 r.random.surface generates a spatially dependent random surface. The
59 random surface is composed of values representing the deviation from
60 the mean of the initial random values driving the algorithm. The ini‐
61 tial random values are independent Gaussian random deviates with a mean
62 of 0 and standard deviation of 1. The initial values are spread over
63 each output map using filter(s) of diameter distance. The influence of
64 each random value on nearby cells is determined by a distance decay
65 function based on exponent. If multiple filters are passed over the
66 output maps, each filter is given a weight based on the weight inputs.
67 The resulting random surface can have "any" mean and variance, but the
68 theoretical mean of an infinitely large map is 0.0 and a variance of
69 1.0. Description of the algorithm is in the NOTES section.
70
71 The random surface generated are composed of floating point numbers,
72 and saved in the category description files of the output map(s). Cell
73 values are uniformly or normally distributed between 1 and high values
74 inclusive (determined by whether the -u flag is used). The category
75 names indicate the average floating point value and the range of float‐
76 ing point values that each cell value represents.
77
78 r.random.surface's original goal is to generate random fields for spa‐
79 tial error modeling. A procedure to use r.random.surface in spatial
80 error modeling is given in the NOTES section.
81
82 Parameters:
83 output
84 Output map(s): Random surface(s). The cell values are a random
85 distribution between the low and high values inclusive. The
86 category values of the output map(s) are in the form "#.# #.# to
87 #.#" where each #.# is a floating point number. The first number
88 is the average of the random values the cell value represents.
89 The other two numbers are the range of random values for that
90 cell value. The "average" mean value of generated output map(s)
91 is 0. The "average" variance of map(s) generated is 1. The ran‐
92 dom values represent the standard deviation from the mean of
93 that random surface.
94
95 distance
96 Input value(s) [default 0.0]: distance determines the spatial
97 dependence of the output map(s). The distance value indicates
98 the minimum distance at which two map cells have no relationship
99 to each other. A distance value of 0.0 indicates that there is
100 no spatial dependence (i.e., adjacent cell values have no rela‐
101 tionship to each other). As the distance value increases, adja‐
102 cent cell values will have values closer to each other. But the
103 range and distribution of cell values over the output map(s)
104 will remain the same. Visually, the clumps of lower and higher
105 values gets larger as distance increases. If multiple values are
106 given, each output map will have multiple filters, one for each
107 set of distance, exponent, and weight values.
108
109 exponent
110 Input value(s) [default 1.0]: exponent determines the distance
111 decay exponent for a particular filter. The exponent value(s)
112 have the property of determining the "texture" of the random
113 surface. Texture will decrease as the exponent value(s) get
114 closer to 1.0. Normally, exponent will be 1.0 or less. If there
115 are no exponent values given, each filter will be given an expo‐
116 nent value of 1.0. If there is at least one exponent value
117 given, there must be one exponent value for each distance value.
118
119 flat
120 Input value(s) [default 0.0]: flat determines the distance at
121 which the filter
122
123 weight
124 Input value(s) [default 1.0]: weight determines the relative
125 importance of each filter. For example, if there were two fil‐
126 ters driving the algorithm and weight=1.0, 2.0 was given in the
127 command line: The second filter would be twice as important as
128 the first filter. If no weight values are given, each filter
129 will be just as important as the other filters defining the ran‐
130 dom field. If weight values exist, there must be a weight value
131 for each filter of the random field.
132
133 high
134 Input value [default 255]: Specifies the high end of the range
135 of cell values in the output map(s). Specifying a very large
136 high value will minimize the "errors" caused by the random sur‐
137 face's discretization. The word errors is in quotes because
138 errors in discretization are often going to cancel each other
139 out and the spatial statistics are far more sensitive to the
140 initial independent random deviates than any potential dis‐
141 cretization errors.
142
143 seed
144 Input value(s) [default random]: Specifies the random seed(s),
145 one for each map, that r.random.surface will use to generate the
146 initial set of random values that the resulting map is based on.
147 If the random seed is not given, r.random.surface will get a
148 seed from the process ID number.
149
151 While most literature uses the term random field instead of random sur‐
152 face, this algorithm always generates a surface. Thus, its use of ran‐
153 dom surface.
154
155 r.random.surface builds the random surface using a filter algorithm
156 smoothing a map of independent random deviates. The size of the filter
157 is determined by the largest distance of spatial dependence. The shape
158 of the filter is determined by the distance decay exponent(s), and the
159 various weights if different sets of spatial parameters are used. The
160 map of independent random deviates will be as large as the current
161 region PLUS the extent of the filter. This will eliminate edge effects
162 caused by the reduction of degrees of freedom. The map of independent
163 random deviates will ignore the current mask for the same reason.
164
165 One of the most important uses for r.random.surface is to determine how
166 the error inherent in raster maps might effect the analyses done with
167 those maps. If you wanted to check to see how sensitive your analysis
168 is to the errors in the DEMs in your study area, see:
169
170 "Visualizing Spatial Data Uncertainty Using Animation (final draft),"
171 by Charles R. Ehlschlaeger, Ashton M. Shortridge, and Michael F. Good‐
172 child. Submitted to Computers in GeoSciences in September, 1996,
173 accepted October, 1996 for publication in June, 1997.
174
175 "Modeling Uncertainty in Elevation Data for Geographical Analysis", by
176 Charles R. Ehlschlaeger, and Ashton M. Shortridge. Proceedings of the
177 7th International Symposium on Spatial Data Handling, Delft, Nether‐
178 lands, August 1996.
179
180 "Dealing with Uncertainty in Categorical Coverage Maps: Defining, Visu‐
181 alizing, and Managing Data Errors", by Charles Ehlschlaeger and Michael
182 Goodchild. Proceedings, Workshop on Geographic Information Systems at
183 the Conference on Information and Knowledge Management, Gaithersburg
184 MD, 1994.
185
186 "Uncertainty in Spatial Data: Defining, Visualizing, and Managing Data
187 Errors", by Charles Ehlschlaeger and Michael Goodchild. Proceedings,
188 GIS/LIS'94, pp. 246-253, Phoenix AZ, 1994.
189
190 If you are interested in creating potential realizations of categorical
191 coverage maps, see r.random.model.
192
194 r.random, r.mapcalc
195
197 Random Field Software for GRASS by Chuck Ehlschlaeger
198
199 As part of my dissertation, I put together several programs that help
200 GRASS (4.1 and beyond) develop uncertainty models of spatial data. I
201 hope you find it useful and dependable. The following papers might
202 clarify their use:
203
204 "Visualizing Spatial Data Uncertainty Using Animation (final draft),"
205 by Charles R. Ehlschlaeger, Ashton M. Shortridge, and Michael F. Good‐
206 child. Submitted to Computers in GeoSciences in September, 1996,
207 accepted October, 1996 for publication in June, 1997.
208
209 "Modeling Uncertainty in Elevation Data for Geographical Analysis", by
210 Charles R. Ehlschlaeger, and Ashton M. Shortridge. Proceedings of the
211 7th International Symposium on Spatial Data Handling, Delft, Nether‐
212 lands, August 1996.
213
214 "Dealing with Uncertainty in Categorical Coverage Maps: Defining, Visu‐
215 alizing, and Managing Data Errors", by Charles Ehlschlaeger and Michael
216 Goodchild. Proceedings, Workshop on Geographic Information Systems at
217 the Conference on Information and Knowledge Management, Gaithersburg
218 MD, 1994.
219
220 "Uncertainty in Spatial Data: Defining, Visualizing, and Managing Data
221 Errors", by Charles Ehlschlaeger and Michael Goodchild. Proceedings,
222 GIS/LIS'94, pp. 246-253, Phoenix AZ, 1994.
223
225 Charles Ehlschlaeger, Michael Goodchild, and Chih-chang Lin; National
226 Center for Geographic Information and Analysis, University of Califor‐
227 nia, Santa Barbara.
228
229 Last changed: $Date: 2006-04-13 21:01:38 +0200 (Thu, 13 Apr 2006) $
230
231 Full index
232
233 © 2003-2008 GRASS Development Team
234
235
236
237GRASS 6.3.0 r.random.surface(1)