Learn R Programming

factor.switching (version 1.4)

plot.rsp: Plot posterior means and credible regions

Description

This function plot posterior mean estimates per factor along with Highest Density Intervals, as well as simultaneous credible regions.

Usage

# S3 method for rsp
plot(x, prob, myCol, mfrow, subSet, simCR, HDI, ...)

Value

A plot.

Arguments

x

An object of class rsp.

prob

Coverage probability of credible regions.

myCol

Vector of colours.

mfrow

Number of rows and columns in the resulting graphic.

subSet

Enable to plot a subset of factors.

simCR

Logical value for plotting simultaneous credible regions. Default: True.

HDI

Logical value for plotting Highest Density Intervals per factor loading. Default: True.

...

Ignored

Author

Panagiotis Papastasmoulis

Examples

Run this code
# load small mcmc sample of 100 iterations
#	with p=6 variables and q=2 factors.
data(small_posterior_2chains)
# post-process it
reorderedPosterior <- rsp_exact(
	lambda_mcmc = small_posterior_2chains[[1]])
# plot it
plot(reorderedPosterior, mfrow = c(1,2), prob=0.95)

Run the code above in your browser using DataLab