Description Usage Arguments Details Value Author(s) References See Also Examples
Produce a summary of the fit, including density, trace and autocorrelation plots.
1 2 | jm.summary(bayes.fit, trace.plot = FALSE, density.plot = FALSE,
autocorr.plot = FALSE)
|
bayes.fit |
fit of the joint model using |
trace.plot |
produce trace plots if TRUE (default is FALSE). |
density.plot |
produce density plots if TRUE (default is FALSE). |
autocorr.plot |
produce autocorrelation plots if TRUE (default is FALSE). |
The coda
package (Plummer et al., 2006) is used to summarize and plot the output from
MCMC simulations. It also includes Gelman-Rubin statistic for convergence diagnostic.
Returns posterior summaries of the parameters, including posterior mean, median, standard deviation, 0.025 and 0.975 quantiles, and Gelman-Rubin statistic values. It also returns some basic information about the model, computational time, and MCMC simulation setup.
Shahedul Khan <khan@math.usask.ca>
Plummer M, Best N, Cowles K, and Vines K, CODA: Convergence diagnosis and output analysis for MCMC, R News, 6: 7-11, 2006.
1 2 3 4 5 6 7 8 9 10 11 12 13 | Consider the pbc data from package JM.
library(JM)
data(aids.id)
data(aids)
surv.fit<-coxph(Surv(Time,death)~drug+gender+prevOI+AZT,
data=aids.id,x=TRUE)
lme.fit<-lme(CD4~obstime+obstime:drug+gender+prevOI+AZT,
random=~obstime|patient,data=aids)
jmfit.ew<-jmreg.aft(surv.fit=surv.fit,lme.fit=lme.fit,
surv.model="eweibull",rand.model="simple",timevar="obstime",
n.chain=2,n.adapt = 5000, n.burn = 15000,
n.iter = 150000, n.thin = 5)
jm.summary(jmfit.ew,trace.plot=TRUE,density.plot=TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.