Description Usage Format Details Source References Examples
The data come to us from Hosmer and Lemeshow (2000). Called the low birth weight (lbw) data, the response is a binary variable, low, which indicates whether the birth weight of a baby is under 2500g (low=1), or over (low=0).
1 |
A data frame with 189 observations on the following 10 variables.
low
1=low birthweight baby; 0=norml weight
smoke
1=history of mother smoking; 0=mother nonsmoker
race
categorical 1-3: 1=white; 2-=black; 3=other
age
age of mother: 14-45
lwt
weight (lbs) at last menstrual period: 80-250 lbs
ptl
number of false of premature labors: 0-3
ht
1=history of hypertension; 0 =no hypertension
ui
1=uterine irritability; 0 no irritability
ftv
number of physician visits in 1st trimester: 0-6
bwt
birth weight in grams: 709 - 4990 gr
lbw is saved as a data frame. Count models can use ftv as a response variable, or convert it to grouped format
Hosmer, D and S. Lemeshow (2000), Applied Logistic Regression, Wiley
Hilbe, Joseph M (2007, 2011), Negative Binomial Regression, Cambridge University Press Hilbe, Joseph M (2009), Logistic Regression Models, Chapman & Hall/CRC
1 2 3 4 5 6 7 8 |
Loading required package: msme
Loading required package: MASS
Loading required package: lattice
Loading required package: sandwich
Call:
glm(formula = ftv ~ low + smoke + factor(race), family = poisson,
data = lbw)
Deviance Residuals:
Min 1Q Median 3Q Max
-1.4052 -1.2238 -1.0950 0.4347 4.1037
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -0.01282 0.14073 -0.091 0.927
low -0.11670 0.19116 -0.610 0.542
smoke -0.15979 0.18253 -0.875 0.381
factor(race)2 -0.09579 0.24849 -0.385 0.700
factor(race)3 -0.33905 0.19933 -1.701 0.089 .
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
(Dispersion parameter for poisson family taken to be 1)
Null deviance: 264.52 on 188 degrees of freedom
Residual deviance: 260.35 on 184 degrees of freedom
AIC: 480.43
Number of Fisher Scoring iterations: 6
(Intercept) low smoke factor(race)2 factor(race)3
0.9872635 0.8898529 0.8523249 0.9086552 0.7124489
Call:
glm.nb(formula = ftv ~ low + smoke + factor(race), data = lbw,
init.theta = 1.896234314, link = log)
Deviance Residuals:
Min 1Q Median 3Q Max
-1.260 -1.121 -1.025 0.373 3.062
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -0.01496 0.17190 -0.087 0.931
low -0.12550 0.22547 -0.557 0.578
smoke -0.15384 0.21794 -0.706 0.480
factor(race)2 -0.09088 0.29782 -0.305 0.760
factor(race)3 -0.33357 0.23585 -1.414 0.157
(Dispersion parameter for Negative Binomial(1.8962) family taken to be 1)
Null deviance: 195.29 on 188 degrees of freedom
Residual deviance: 192.36 on 184 degrees of freedom
AIC: 471.95
Number of Fisher Scoring iterations: 1
Theta: 1.896
Std. Err.: 0.798
2 x log-likelihood: -459.954
(Intercept) low smoke factor(race)2 factor(race)3
0.9851477 0.8820544 0.8574067 0.9131278 0.7163583
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.