plot.regressionTable: Plotting regression coefficients with confidence limits

View source: R/plot.regressionTable.R

plot.regressionTableR Documentation

Plotting regression coefficients with confidence limits

Description

Plotting regression coefficients with confidence limits

Usage

## S3 method for class 'regressionTable'
plot(x, xlim, xlab, style = 1, ...)

Arguments

x

regression table obtained with regressionTable

xlim

Limits for x-axis

xlab

Label for x-axis

style

Determines how to arrange variable names and their corresponding units

...

passed to plotConfidence

Author(s)

Thomas A. Gerds <tag@biostat.ku.dk>

See Also

regressionTable

Examples

## linear regression
data(Diabetes)
f <- glm(bp.1s~AgeGroups+chol+gender+location,data=Diabetes)
rtf <- regressionTable(f,factor.reference = "inline")
plot(rtf,cex=1.3)

## logistic regression
data(Diabetes)
f <- glm(I(BMI>25)~bp.1s+AgeGroups+chol+gender+location,data=Diabetes,family=binomial)
rtf <- regressionTable(f,factor.reference = "inline")
plot(rtf,cex=1.3)

## Poisson regression
data(trace)
fit <- glm(dead ~ smoking+ sex+ age+Time+offset(log(ObsTime)), family = poisson,data=trace)
rtab <- regressionTable(fit,factor.reference = "inline")
plot(rtab,xlim=c(0.85,1.15),cex=1.8,xaxis.cex=1.5)

## Cox regression
library(survival)
data(pbc)
coxfit <- coxph(Surv(time,status!=0)~age+log(bili)+log(albumin)+factor(edema)+sex,data=pbc)
pubcox <- publish(coxfit)
plot(pubcox,cex=1.5,xratio=c(0.4,0.2))


Publish documentation built on Jan. 18, 2023, 1:08 a.m.