| plot.qreg.spike {BoomSpikeSlab} | R Documentation |
Plot the results of a spike and slab regression.
Description
The default plot is a barplot of the marginal inclusion probabilities
for each variable, as obtained by
PlotMarginalInclusionProbabilities. Other interesting
plots can be obtained by supplying a string as the second argument.
Usage
## S3 method for class 'qreg.spike'
plot(x,
y = c("inclusion", "coefficients", "scaled.coefficients",
"size", "help"),
burn = SuggestBurnLogLikelihood(x$log.likelihood),
...)
Arguments
x |
An object of class |
y |
The type of plot desired. |
burn |
The number of MCMC iterations to discard as burn-in. |
... |
Additional arguments passed to the specific functions that do the plotting. |
Details
The actual plotting will be handled by
PlotMarginalInclusionProbabilities,
PlotLmSpikeCoefficients, or PlotModelSize.
See the appropriate function for more options.
Author(s)
Steven L. Scott
See Also
PlotMarginalInclusionProbabilities
PlotLmSpikeCoefficients
PlotModelSize
qreg.spike
SpikeSlabPrior
predict.qreg.spike
Examples
n <- 50
x <- rnorm(n)
y <- rnorm(n, 4 * x)
model <- qreg.spike(y ~ x,
quantile = .8,
niter = 1000,
expected.model.size = 100)
plot(model)
plot(model, "coef")
plot(model, "coefficients")
plot(model, "scaled.coefficients")
plot(model, "scal")
plot(model, "size")
plot(model, "help")
[Package BoomSpikeSlab version 1.2.6 Index]