Get_Rdiag: Checking convergence: diagnostics

Description Usage Arguments Author(s) See Also Examples

View source: R/est_mix_intensity.R

Description

This function reports the Gelman-Rubin convergence diagnostic R (also known as the potential scale reduction), by producing k DAMCMC fits and computing the within-chain and between-chain variances. Values approximately equal to 1 indicate convergence, otherwise we need to run the chain for a longer number of iterations to get convergence.

For DAMCMC examples see

http://faculty.missouri.edu/~micheasa/sppmix/sppmix_all_examples.html#Get_Rdiag

Usage

1
2
Get_Rdiag(pp, m, truncate = FALSE, L = 20000, numofchains = 2,
  permute = 0)

Arguments

pp

Point pattern object of class ppp.

m

The number of components to fit.

truncate

Logical variable indicating whether or not we normalize the densities of the mixture components to have all their mass within the window defined in the point pattern pp.

L

Number of iterations to use for each chain created; default is 20000. Note that half of them will be dropped so use a large number.

numofchains

Number of chains to create; default is 2.

permute

Request to generate chains that are unpermuted (permute=0), identifiability constraint (IC) permuted (permute=1), or minimum squared error loss (SEL) permuted (permute=2).

Author(s)

Sakis Micheas

See Also

est_mix_damcmc, rmixsurf, rsppmix

Examples

1
2
3
4
truemix_surf <- rmixsurf(m = 3, lambda=100, xlim = c(-3,3), ylim = c(-3,3))
plot(truemix_surf)
genPPP=rsppmix(intsurf = truemix_surf, truncate = FALSE)
Get_Rdiag(pp = genPPP, m = 3)

sppmix documentation built on Jan. 13, 2021, 10:04 p.m.