| simulate.mppm {spatstat.model} | R Documentation |
Simulate a Point Process Model Fitted to Several Point Patterns
Description
Generates simulated realisations from a point process model that was fitted to several point patterns.
Usage
## S3 method for class 'mppm'
simulate(object, nsim=1, ..., verbose=TRUE)
Arguments
object |
Point process model fitted to several point patterns.
An object of class |
nsim |
Number of simulated realisations (of each original pattern). |
... |
Further arguments passed to |
verbose |
Logical value indicating whether to print progress reports. |
Details
This function is a method for the generic function
simulate for the class "mppm" of fitted
point process models for replicated point pattern data.
The result is a hyperframe with n rows and nsim columns,
where n is the number of original point pattern
datasets to which the model was fitted. Each column of the hyperframe
contains a simulated version of the original data.
For each of the original point pattern datasets, the
fitted model for this dataset is extracted using
subfits, then nsim simulated realisations
of this model are generated using simulate.ppm,
and these are stored in the corresponding row of the output.
Value
A hyperframe.
Author(s)
Adrian Baddeley Adrian.Baddeley@curtin.edu.au, Rolf Turner rolfturner@posteo.net and Ege Rubak rubak@math.aau.dk.
See Also
Examples
H <- hyperframe(Bugs=waterstriders)
fit <- mppm(Bugs ~ id, H)
y <- simulate(fit, nsim=2)
y
plot(y[1,,drop=TRUE], main="Simulations for Waterstriders pattern 1")
plot(y[,1,drop=TRUE], main="Simulation 1 for each Waterstriders pattern")