plot.diplotype.ci: Plot approximate posterior credible intervals of diplotype...

View source: R/plot_lib.R

plot.diplotype.ciR Documentation

Plot approximate posterior credible intervals of diplotype effects as a caterpillar plot

Description

This function takes a Diploffect.INLA summary object and plots the posterior credible intervals of the diplotype effects, which are a linear combination of the additive and dominant effects.

Usage

## S3 method for class 'diplotype.ci'
plot(
  inla.diploffect.ci,
  sn = NULL,
  xlab = "Diplotype Effects",
  flip = TRUE,
  ...
)

Arguments

inla.diploffect.ci

A Diploffect.INLA summary object. Output from run.diploffect.inla.summary.stats(). Contains credible information for various model parameters.

sn

DEFAULT: NULL. Strain names to be used as labels in the plot. Will default to the names used in the Diploffect.INLA model probabilities.

xlab

DEFAULT: "Diplotype Effects". Label for the x axis of the plot.

flip

DEFAULT: TRUE. Flips the order of the haplotypes. Allows a little flexibility in how the effects are arranged.

Value

Nothing. Produces plot.

Examples

library(Diploffect.INLA)
data(exampleCC)
data(locusmatrix)
inla.diploffect <- run.diploffect.inla(formula=y~1+(1|strain)+(1|dose.date), add.on=FALSE, data=exampleCC, K=NULL,
                                       prob.matrix=locusmatrix,
                                       num.draws=10, 
                                       use.dip.lincomb=TRUE, seed=1, gamma.rate=1, impute.on="CCline")
inla.diploffect.summary <- run.diploffect.inla.summary.stats(inla.diploffect)
plot_diplotype.ci(inla.diploffect.summary, flip=FALSE)

gkeele/Diploffect.INLA documentation built on May 17, 2023, 8:37 a.m.