Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

chdage

Coronary Heart Disease


Description

A well known explanation of the heart disease is that as the age increases, the risk of coronary heart disease also increase. The current data set and the example may be found in Chapter 1 of Hosmer and Lemeshow (1990-2013).

Usage

data(chdage)

Format

A data frame with 100 observations on the following 3 variables.

ID

patient ID

AGE

age of the patient

CHD

Coronary Heart Disease indicator

Source

Hosmer and Lemeshow (1990-2013).

References

Hosmer, D.W., and Lemeshow, S. (1990-20013). Applied Logistic Regression, 3e. Wiley.

Examples

data(chdage)
plot(chdage$AGE,chdage$CHD,xlab="AGE",ylab="CHD Indicator", 
main="Scatter plot for CHD Data")
agegrp <- cut(chdage$AGE,c(19,29,34,39,44,49,54,59,69),include.lowest=TRUE,
labels=c(25,seq(31.5,56.5,5),64.5))
mp <- c(25,seq(31.5,56.5,5),64.5) # mid-points
chd_percent <- prop.table(table(agegrp,chdage$CHD),1)[,2]
points(mp,chd_percent,"l",col="red")

ACSWR

A Companion Package for the Book "A Course in Statistics with R"

v1.0
GPL-2
Authors
Prabhanjan Tattar
Initial release
2015-09-05

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.