gelman.brooks.plot {RJaCGH} | R Documentation |
A plot to show the convergence of several parallel chains, as described in Brooks and Gelman, 1998.
gelman.brooks.plot(obj, bin = 1000, array = NULL, Chrom = NULL, k = NULL)
obj |
a list containing several parallel chains; that is objects of any of RJaCGH, RJaCGH.Chrom, RJaCGH.genome, RJaCGH.array classes (obviously, all of the same class). |
bin |
Number of observations taken in every subchain |
array |
if obj is 'RJaCGH.array', the name of the array to
plot must be given. |
Chrom |
if obj is 'RJaCGH.Chrom', the number of the chromosome to
plot must be given. |
k |
Model to monitorize (i.e., number of hidden states). If NULL, the most visited is taken. |
As described in the references, for every bin
runs of the
chain, the R value of k
, mu
, sigma.2
and beta
are computed.
A plot showing the R values is drawn. Besides, a list is returned with components
k |
R values for the numebr of states |
mu |
R values for the means of the states |
mu |
R values for the variances of the states |
mu |
R values for the beta parameters |
Oscar Rueda and Ramon Diaz Uriarte
Brooks, S.P. and Gelman, A. (1998). General Methods for Monitoring convergence of iterative simulations. Journal of Computational and Graphical Statistics. p434-455.
Oscar Rueda and Ramon Diaz Uriarte, in prep.
RJaCGH
,
summary.RJaCGH
, model.averaging
,
plot.RJaCGH
, states
,
trace.plot
, collapseChain
y <- c(rnorm(100, 0, 1), rnorm(10, -3, 1), rnorm(20, 3, 1), rnorm(100,0, 1)) Pos <- runif(230) Pos <- cumsum(Pos) Chrom <- rep(1:23, rep(10, 23)) jp <- list(sigma.tau.mu=rep(0.5, 4), sigma.tau.sigma.2=rep(0.3, 4), sigma.tau.beta=rep(0.7, 4), tau.split.mu=0.5, tau.split.beta=0.5) fit.genome <- list() for (i in 1:4) { fit.genome[[i]] <- RJaCGH(y=y, Pos=Pos, Chrom=Chrom, model="genome", burnin=10, TOT=1000, jump.parameters=jp, k.max = 4) } ## Not run: gelman.brooks.plot(fit.genome)