| rpoisDirichletTess | R Documentation |
Generate a random tessellation of a given spatial region, using the Dirichlet tessellation defined by a Poisson point process on the infinite plane.
rpoisDirichletTess(lambda, win = owin())
lambda |
Intensity of the Poisson point process. Either a single positive number, or a function which can be evaluated at any spatial location. |
win |
Window to be divided into tiles.
An object of class |
This algorithm computes the Dirichlet-Voronoi tessellation
of the window win induced by a Poisson point process
on the infinite two-dimensional plane, avoiding edge effects.
The argument lambda is the intensity of the Poisson process.
It should be either a single positive number, or a
function(x,y)
which can be evaluated at any spatial location (x,y).
The algorithm is a modification of Algorithm C_2
of Hinde and Miles (1980).
It first generates a realisation of the Poisson process
inside win, and computes the Dirichlet-Voronoi tessellation
of this point pattern. Then in order to avoid edge effects,
the algorithm calculates the
maximum possible distance d outside the window
such that a random point outside w could affect the
outcome inside w. The window is expanded by this distance
d; the realisation of the Poisson process in the expanded region
is generated; and the Dirichlet-Voronoi tessellation of the augmented
point pattern is computed, then restricted to the original window.
If lambda is a single number, the result is a realisation
of a stationary random tessellation (restricted to win).
A tessellation (object of class "tess").
Also has an attribute "X" containing the realisation of the
Poisson point process (restricted to those points which affected the
result).
.
Hinde, A.L. and Miles, R.E. (1980) Monte Carlo estimates of the distribution of the random polygons of the Voronoi tessellation with respect to a Poisson process. J. Statist. Comput. Simul. 10, 205–223.
rpoislinetess
A <- rpoisDirichletTess(10)
X <- attr(A, "X")
plot(Frame(X), type="n", main="rpoisDirichletTess(10)")
plot(A, add=TRUE)
plot(X, add=TRUE, pch=16)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.