Simulate a Fitted Spatial Logistic Regression Model
Generates simulated realisations from a fitted spatial logistic regresson model
## S3 method for class 'slrm': simulate(object, nsim = 1, seed=NULL, ..., window=NULL, covariates=NULL, verbose=TRUE)
- Fitted spatial logistic regression model. An object of class
- Number of simulated realisations.
- an object specifying whether and how to initialise
the random number generator. Either
NULLor an integer that will be used in a call to
set.seedbefore simulating the p
- Optional. Window (object of class
"owin") in which the model should be simulated.
- Optional. A named list containing new values for the covariates in the model.
- Logical. Whether to print progress reports (when
nsim > 1).
This function is a method for the generic function
simulate for the class
"slrm" of fitted
spatial logistic regression models.
Simulations are performed by
after the intensity has been computed by
The return value is a list of point patterns.
It also carries an attribute
captures the initial state of the random number generator.
This follows the convention used in
It can be used to force a sequence of simulations to be
repeated exactly, as shown in the examples for
- A list of length
nsimcontaining simulated point patterns (objects of class
The return value also carries an attribute
"seed"that captures the initial state of the random number generator. See Details.
X <- copper$SouthPoints fit <- slrm(X ~ 1) simulate(fit, 2) fitxy <- slrm(X ~ x+y) simulate(fitxy, 2, window=square(2))