Skip to contents

Categorical (visual) predictive check plots.

Usage

cat.pc(
  object,
  dv = xvardef("dv", object),
  idv = xvardef("idv", object),
  level.to.plot = NULL,
  subset = NULL,
  histo = T,
  median.line = F,
  PI.lines = F,
  xlb = if (histo) {
     paste("Proportion of ", dv)
 } else {
     paste(idv)
 },
  ylb = if (histo) {
     paste("Percent of Total")
 } else {
    
    paste("Proportion of Total")
 },
  main = xpose.create.title.text(NULL, dv, "Predictive check of", object, subset =
    subset, ...),
  strip = "Default",
  ...
)

Arguments

object

Xpose data object.

dv

The dependent variable (e.g. "DV" or "CP".)

idv

The independent variable (e.g. "TIME".)

level.to.plot

The levels to plot.

subset

Subset of data.

histo

If FALSE then a VPC is created, given that idv is defined.

median.line

Make a median line?

PI.lines

Make prediction interval lines?

xlb

Label for x axis.

ylb

label for y axis.

main

Main title.

strip

Defining how the strips should appear in the conditioning plots.

...

Extra arguments passed to the function.

Author

Andrew C. Hooker

Examples


if (FALSE) {
## read in table files
runno <- 45
xpdb <- xpose.data(runno)

## create proportion (visual) predictive check
cat.pc(xpdb,idv=NULL)
cat.pc(xpdb,idv="DOSE")
cat.pc(xpdb,idv="DOSE",histo=F)
cat.pc(xpdb,idv="TIME",histo=T,level.to.plot=1)
}