Learn R Programming

ordinalCont (version 0.4)

plot.ocm: Plot method for Continuous Ordinal Fits

Description

Plots the g function as fitted in an ocm call.

Usage

"plot"(x, CIs = c("no", "vcov", "rnd.x.bootstrap", "fix.x.bootstrap", "param.bootstrap"), R = 1000, main = "g function (95% CIs)", xlab = "Continuous ordinal scale", ylab = "", CIcol = "lightblue", ...)

Arguments

x
an object of class ocm
CIs
method used for confidence bands for the g function. "no" = no CIS [default]; "vcov" = Wald; "rnd.x.bootstrap" = random-x bootstrap; "fix.x.bootstrap" = bootstrap with fixed-x resampling; "param.bootstrap" = parametric bootstrap
R
the number of bootstrap replicates. Ignored if CIs="no"
main
title of the plot. Defauts to ``g function (95% CIs)''
xlab
label of the x axis. Defaults to ``Continuous ordinal scale''
ylab
label of the y axis. Defaults to an emtpy string
CIcol
color of the confidence interval bands. Defaults to ``lightblue''
...
further arguments passed to or from other methods

Details

The fitted g function of an ocm object is plotted. If CIs is not "no", 95% confidence bands are also plotted. Confidence bands computed with any of the bootstrapping options are obtained with simple percentiles.

See Also

ocm

Examples

Run this code
ANZ0001.ocm <- ANZ0001[ANZ0001$cycleno==0 | ANZ0001$cycleno==5,]
ANZ0001.ocm$cycleno[ANZ0001.ocm$cycleno==5] <- 1
fit.overall  <- ocm(overall  ~ cycleno + age + bsa + treatment, data=ANZ0001.ocm)
plot(fit.overall, CIs="vcov")
## Not run: 
# plot(fit.overall, CIs="rnd.x.bootstrap", R=100)
# plot(fit.overall, CIs="fix.x.bootstrap", R=100)
# plot(fit.overall, CIs="param.bootstrap", R=100)
# ## End(Not run)

Run the code above in your browser using DataLab