浏览代码

r.random*/r.surf.* manuals: examples and screenshots added (#1542)

- r.random manual: example update to NC
- r.random.surface manual: examples added
- r.surf.gauss manual: new screenshots 
- r.surf.random manual: new screenshots
Markus Neteler 4 年之前
父节点
当前提交
665be72774

+ 1 - 1
raster/r.random.cells/r.random.cells.html

@@ -38,7 +38,7 @@ using <em>r.2Dcorrelogram</em> with
 zero, the <b>output</b> map will number each non-masked cell from 1 to the
 number of non-masked cells in the study region. -->
 
-<h2>EXAMPLE</h2>
+<h2>EXAMPLES</h2>
 
 <h3>Random cells in given distances</h3>
 

二进制
raster/r.random.cells/r_random_cells.png


+ 46 - 11
raster/r.random.surface/r.random.surface.html

@@ -108,6 +108,40 @@ ignore the current mask for the same reason.
 how the error inherent in raster maps might effect the analyses done with
 those maps.
 
+
+<h2>EXAMPLE</h2>
+
+Generate a random surface (using extent of North Carolina sample dataset):
+
+<div class="code"><pre>
+g.region raster=elevation res=100 -p
+r.surf.random output=randomsurf min=10 max=100
+
+# verify distribution
+r.univar -e map=randomsurf
+</pre></div>
+
+<!--
+d.legend -d raster=randomsurf@user1 title=randomsurf font=Vera
+-->
+
+<div align="center" style="margin: 10px">
+<a href="r_random_surface.jpg">
+<img src="r_random_surface.jpg" width="600" height="288" alt="r.random.surface example (n_min: 10; n_max: 100)" border="0">
+</a><br>
+<i>Figure: Random surface example (min: 10; max: 100)</i>
+</div>
+
+<p>
+With the histogram tool the cell values versus count can be shown.
+<p>
+<div align="center" style="margin: 10px">
+<a href="r_random_surface_hist.png">
+<img src="r_random_surface_hist.png" width="600" height="244" alt="r.random.surface example histogram (n_min: 10; n_max: 100)" border="0">
+</a><br>
+<i>Figure: Histogram of random surface example (min: 10; max: 100)</i>
+</div>
+
 <h2>REFERENCES</h2>
 Random Field Software for GRASS by Chuck Ehlschlaeger
 
@@ -119,25 +153,26 @@ use:
 <ul>
 <li> Ehlschlaeger, C.R., Shortridge, A.M., Goodchild, M.F., 1997. 
  Visualizing spatial data uncertainty using animation. 
- Computers & Geosciences 23, 387-395. doi:10.1016/S0098-3004(97)00005-8</li>
+ Computers &amp; Geosciences 23, 387-395.
+ doi:<a href="https://doi.org/10.1016/S0098-3004(97)00005-8">10.1016/S0098-3004(97)00005-8</a></li>
 
-<li><a href="http://www.geo.hunter.cuny.edu/~chuck/paper.html">Modeling
-Uncertainty in Elevation Data for Geographical Analysis</a>, by
-Charles R. Ehlschlaeger, and Ashton M.  Shortridge. Proceedings of the
+<li> Ehlschlaeger, C.R., Shortridge, A.M., 1996.
+<a href="http://www.geo.hunter.cuny.edu/~chuck/paper.html">Modeling
+Uncertainty in Elevation Data for Geographical Analysis</a>. Proceedings of the
 7th International Symposium on Spatial Data Handling, Delft,
 Netherlands, August 1996.</li>
 
-<li><a href="http://www.geo.hunter.cuny.edu/~chuck/acm/paper.html">Dealing
+<li> Ehlschlaeger, C.R., Goodchild, M.F., 1994.
+<a href="http://www.geo.hunter.cuny.edu/~chuck/acm/paper.html">Dealing
 with Uncertainty in Categorical Coverage Maps: Defining, Visualizing,
-and Managing Data Errors</a>, by Charles Ehlschlaeger and Michael
-Goodchild.  Proceedings, Workshop on Geographic Information Systems at
-the Conference on Information and Knowledge Management, Gaithersburg
+and Managing Data Errors</a>. Proceedings, Workshop on Geographic Information
+Systems at the Conference on Information and Knowledge Management, Gaithersburg
 MD, 1994.</li>
 
-<li><a href="http://www.geo.hunter.cuny.edu/~chuck/gislis/gislis.html">Uncertainty
+<li> Ehlschlaeger, C.R., Goodchild, M.F., 1994.
+<a href="http://www.geo.hunter.cuny.edu/~chuck/gislis/gislis.html">Uncertainty
 in Spatial Data: Defining, Visualizing, and Managing Data
-Errors</a>, by Charles Ehlschlaeger and Michael
-Goodchild. Proceedings, GIS/LIS'94, pp. 246-253, Phoenix AZ,
+Errors</a>. Proceedings, GIS/LIS'94, pp. 246-253, Phoenix AZ,
 1994.</li>
 </ul>
 

二进制
raster/r.random.surface/r_random_surface.jpg


二进制
raster/r.random.surface/r_random_surface_hist.png


+ 23 - 18
raster/r.random/r.random.html

@@ -55,7 +55,7 @@ of sites to have <em>r.random</em> create.
 instead.
 <div class="code"><pre>
 g.region -p
-r.report map=inputmap units=c null=* nsteps=1
+r.report map=inputmap units=c null="*" nsteps=1
 </pre></div>
 
 <p>To create random vector point locations within some, but not all, 
@@ -67,46 +67,51 @@ that contains only the desired categories,
 and then use the reclassed raster map layer as input to <em>r.random</em>.
 
 <h2>EXAMPLES</h2>
-<p>Random vector elevation points sampled from elevation map in the
-Spearfish region, result stored in 2D vector map:
+
+<h3>Random 2D vector elevation points</h3>
+
+Random vector elevation points sampled from elevation map in the
+North Carolina sample dataset region, result stored in 2D vector map:
 
 <div class="code"><pre>
-g.region raster=elevation.10m -p
-r.random elevation.10m vector=elevrand n=100
+g.region raster=elevation -p
+r.random elevation vector=elevrand n=100
 v.db.select elevrand
 v.univar elevrand col=value type=point
 </pre></div>
 
+<h3>Random 3D vector elevation points</h3>
 
-<p>Random vector elevation points sampled from elevation map in the
-Spearfish region with collocated values sampled from landuse map,
-result stored in 3D vector map:
+Random vector elevation points sampled from elevation map in the
+North Carolina sample dataset region with collocated values sampled from
+landuse map, result stored in 3D vector map:
 
 <div class="code"><pre>
-g.region raster=elevation.10m -p
-r.random -d elevation.10m cover=landcover.30m vector=luserand3d n=100
+g.region raster=elevation -p
+r.random -d elevation cover=landclass96 vector=luserand3d n=100
 
 # data output (value: elevation, covervalue: landuse class):
 v.db.select luserand3d
 cat|value|covervalue
-1|1151.406616|81
-2|1172.121216|71
-3|1183.219604|71
+1|111.229591|5
+2|71.093758|1
+3|122.51075|5
+4|146.17395|4
 ...
 </pre></div>
 
 <h2>KNOWN ISSUES</h2>
 
-It's not possible to use the <b>-i</b> flag and not also specify the <b>n</b> 
-parameter.
+It's not possible to use the <b>-i</b> flag without specifying the
+<b>npoints</b> parameter.
 
 
 <h2>SEE ALSO</h2>
 
 <em>
-<a href="g.region.html">g.region</a><br>
-<a href="r.reclass.html">r.reclass</a><br>
-<a href="v.random.html">v.random</a><br>
+<a href="g.region.html">g.region</a>,
+<a href="r.reclass.html">r.reclass</a>,
+<a href="v.random.html">v.random</a>,
 <a href="v.surf.rst.html">v.surf.rst</a>
 </em>
 

+ 21 - 5
raster/r.surf.gauss/r.surf.gauss.html

@@ -6,11 +6,6 @@ Gaussian random number generator. It is essentially the same
 as <em><a href="r.surf.random.html">r.surf.random</a></em>, but uses a
 Gaussian random number generator instead.
 
-<center>
-<img src="r_surf_gauss_hist.png" alt="r.surf.gauss map histogram"><br>
-<i>Histogram of map generated with r.surf.gauss (mean=0, sigma=10)</i>
-</center>
-
 <h2>EXAMPLE</h2>
 
 <div class="code"><pre>
@@ -21,6 +16,27 @@ r.surf.gauss out=gauss mean=0 sigma=10
 r.univar gauss
 </pre></div>
 
+<!--
+d.legend -d raster=gauss@user1 title=Gauss font=Vera
+-->
+
+<div align="center" style="margin: 10px">
+<a href="r_surf_gauss.jpg">
+<img src="r_surf_gauss.jpg" width="600" height="295" alt="r.surf.gauss example (mean: 0; sigma: 10)" border="0">
+</a><br>
+<i>Figure: Random Gaussian surface example (mean: 0; sigma: 10)</i>
+</div>
+
+<p>
+With the histogram tool the cell values versus count can be shown.
+<p>
+<div align="center" style="margin: 10px">
+<a href="r_surf_gauss_hist.png">
+<img src="r_surf_gauss_hist.png" width="600" height="275" alt="r.surf.gauss example histogram (mean: 0; sigma: 10)" border="0">
+</a><br>
+<i>Figure: Histogram of random Gaussian surface example (mean: 0; sigma: 10)</i>
+</div>
+
 <h2>SEE ALSO</h2>
 
 <em>

二进制
raster/r.surf.gauss/r_surf_gauss.jpg


二进制
raster/r.surf.gauss/r_surf_gauss_hist.png


+ 22 - 5
raster/r.surf.random/r.surf.random.html

@@ -6,11 +6,6 @@ whose range can be expressed by the user. It is essentially the same as
 It uses the random number generator drand48() or rand()<!-- cite? -->,
 depending on the user's platform.
 
-<p><center>
-<img src="r_surf_random_hist.png" alt="r.surf.random map histogram"><br>
-<i>Histogram of map generated with r.surf.random</i>
-</center>
-
 <h2>EXAMPLE</h2>
 
 <div class="code"><pre>
@@ -21,6 +16,28 @@ r.surf.random out=random min=0 max=100
 r.univar random
 </pre></div>
 
+<!--
+d.legend -d raster=random@user1 title=random font=Vera
+-->
+
+<div align="center" style="margin: 10px">
+<a href="r_surf_random.jpg">
+<img src="r_surf_random.jpg" width="600" height="293" alt="r.random.surface example (min: 10; max: 100)" border="0">
+</a><br>
+<i>Figure: Random surface example (min: 10; max: 100)</i>
+</div>
+
+<p>
+With the histogram tool the cell values versus count can be shown.
+<p>
+<div align="center" style="margin: 10px">
+<a href="r_surf_random_hist.png">
+<img src="r_surf_random_hist.png" width="600" height="280" alt="r.random.surface example histogram (min: 10; max: 100)" border="0">
+</a><br>
+<i>Figure: Histogram of random surface example (min: 10; max: 100)</i>
+</div>
+
+
 <h2>SEE ALSO</h2>
 
 <em>

二进制
raster/r.surf.random/r_surf_random.jpg


二进制
raster/r.surf.random/r_surf_random_hist.png