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

View source: R/betaBinomial.R

plot.cnormBetaBinomialR Documentation

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 class 'cnormBetaBinomial'
plot(x, ...)

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.

Value

A ggplot object.

See Also

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

Examples


## Not run: 
# 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)


## End(Not run)

cNORM documentation built on Nov. 4, 2024, 5:07 p.m.