simulate.kppm {spatstat}R Documentation

Simulate a Fitted Cluster Point Process Model

Description

Generates simulated realisations from a fitted cluster point process model.

Usage

  ## S3 method for class 'kppm':
  simulate(object, nsim = 1, seed=NULL, ...,
         window=NULL, covariates=NULL)

Arguments

object Fitted cluster point process model. An object of class "kppm".
nsim Number of simulated realisations.
seed an object specifying whether and how to initialise the random number generator. Either NULL or an integer that will be used in a call to set.seed before simulating the point patterns.
... Ignored.
window Optional. Window (object of class "owin") in which the model should be simulated.
covariates Optional. A named list containing new values for the covariates in the model.

Details

This function is a method for the generic function simulate for the class "kppm" of fitted cluster point process models.

Simulations are performed by rThomas or rMatClust depending on the cluster mechanism.

The return value is a list of point patterns. It also carries an attribute "seed" that captures the initial state of the random number generator. This follows the convention used in simulate.lm (see simulate). It can be used to force a sequence of simulations to be repeated exactly, as shown in the examples for simulate.

Value

A list of length nsim containing simulated point patterns (objects of class "ppp").
The return value also carries an attribute "seed" that captures the initial state of the random number generator. See Details.

Author(s)

Adrian Baddeley adrian@maths.uwa.edu.au http://www.maths.uwa.edu.au/~adrian/ and Rolf Turner r.turner@auckland.ac.nz

See Also

kppm, simulate.ppm, simulate

Examples

  data(redwood)
  fit <- kppm(redwood, ~1, "Thomas")
  simulate(fit, 2)

[Package spatstat version 1.17-0 Index]