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