SimulateTypeA: Simulation of the Generalized Thomas Model of Type A

Description Usage Arguments Details Value References Examples

View source: R/NScluster.R

Description

Simulation of the generalized Thomas model of type A.

Usage

1
  SimulateTypeA(pars, seed = NULL, plot = TRUE)

Arguments

pars

a named vector of containing the values of the model parameters (mu, nu, a, sigma1, sigma2), where mu is an intensity of parents, nu is an expected number of descendants for each parent, a is a mixture parameter, sigma1 and sigma2 are parameters of the dispersal kernel for each component.

seed

a positive integer, which is the seed for a sequence of uniform random numbers. The default seed is based on the current time.

plot

logical. If TRUE (default), simulated parent points and offspring points are plotted.

Details

Parents' configuration and numbers of the offspring cluster sizes are generated by the same way as the Thomas model.

Let random variable Uk, k=1,2 be independently and uniformly distributed in [0,1]. Then r satisfies as follows:

r = σ1 √{ -2log(1-U1) }, U2 <= a ,

r = σ2 √{ -2log(1-U1) }, otherwise.

Each of the offspring coordinates (x_j^i, y_j^i) is given like that of SimulateIP. Using series of different uniform random numbers {U1, U2, U} for different i and j.

Value

parents

a list containing two components named "n" and "xy" giving the number and the matrix of (x,y) coordinates of simulated parents points respectively.

offspring

a list containing two components named "n" and "xy" giving the number and the matrix of (x,y) coordinates of simulated offspring points respectively.

References

U. Tanaka, Y. Ogata and K. Katsura, Simulation and estimation of the Neyman-Scott type spatial cluster models, Computer Science Monographs No.34, 2008, 1-44. The Institute of Statistical Mathematics.

Examples

1
2
pars <- c(mu = 50.0, nu = 30.0, a = 0.03, sigma1 = 0.005, sigma2 = 0.1)
SimulateTypeA(pars, seed = 575)

NScluster documentation built on March 19, 2018, 9:03 a.m.