Description Usage Arguments Value Note Examples
Computes Rhat for all nsubjects x nsubsets parameters across the list of models, treated as separate chains. Flags cell populations and subjects with Rhat > 1.01. The most frequently flagged population is passed for further diagnostis to compute Rhat between all pairs of models and to try and identify the model or models that are outliers. The outliers are removed and a list of good models is returned.
1 | checkCOMPASSConvergence(mlist, ncores = 1)
|
mlist |
A list of COMPASSResult models. Each should be fit to the same data, but with different seeds. |
ncores |
The number of cores to use, if supported on the system. |
A list of COMPASSResult models that are consistent / have converged.
Uses foreach and doMC, so it won't work on windows.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | data(COMPASS)
set.seed(100)
fit <- COMPASS(CC,
category_filter=NULL,
treatment=trt == "Treatment",
control=trt == "Control",
verbose=FALSE,
iterations=100 ## set higher for a real analysis
)
set.seed(200)
fit2 <- COMPASS(CC,
category_filter=NULL,
treatment=trt == "Treatment",
control=trt == "Control",
verbose=FALSE,
iterations=100 ## set higher for a real analysis
)
checkCOMPASSConvergence(list(fit,fit2))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.