Learn R Programming

cNORM (version 3.3.1)

plot.cnormBetaBinomial: Plot cnormBetaBinomial Model with Data and Percentile Lines

Description

This function creates a visualization of a fitted cnormBetaBinomial model, including the original data points manifest percentiles and specified percentile lines.

Usage

# S3 method for cnormBetaBinomial
plot(x, ...)

Value

A ggplot object.

Arguments

x

A fitted model object of class "cnormBetaBinomial" or "cnormBetaBinomial2".

...

Additional arguments passed to the plot method.

  • age A vector the age data.

  • A vector of the score data.

  • weights An optional numeric vector of weights for each observation.

  • percentiles An optional vector with the percentiles to plot.

  • points Logical indicating whether to plot the data points. Default is TRUE.

See Also

Other plot: plot.cnorm(), plot.cnormBetaBinomial2(), plotDensity(), plotDerivative(), plotNorm(), plotNormCurves(), plotPercentileSeries(), plotPercentiles(), plotRaw(), plotSubset()

Examples

Run this code

if (FALSE) {
# Computing beta binomial models already displays plot
model.bb <- cnorm.betabinomial(elfe$group, elfe$raw)

# Without data points
plot(model.bb, age = elfe$group, score = elfe$raw, weights=NULL, points=FALSE)

}

Run the code above in your browser using DataLab