20 - Stanford University
Lab Seven: Conditional logistic regression for matched data and ordinal logistic regression for ordinal response variables
Lab Objectives
After today’s lab you should be able to:
1. Run conditional logistic regression for matched data.
2. Interpret output from conditional logistic regression.
3. Run an ordinal logistic regression
4. Interpret output from ordinal logistic regression.
LAB EXERCISE STEPS:
Follow along with the computer in front…
1. Download the TWO lab 7 datasets (matched and runners) from the class website (already in SAS format!).
stanford.edu/~kcobb/courses/hrp261 (right click on LAB 7 DATA (matched, runners)(save to desktop
Dataset 1: matched:
Researchers in a Midwestern county tracked flu cases requiring hospitalization in those residents aged 65 and older during a two-month period one winter. They matched each case with 2 controls by sex and age (150 cases, 300 controls). They used medical records to determine whether cases and controls had received a flu vaccine shot and whether they had underlying lung disease. They wanted to know whether flu vaccination prevents hospitalization for flu (severe cases of flu). Underlying lung disease is a potential confounder. Example modified from: Stokes, Davis, Koch (2000). “Categorical Data Analysis Using the SAS System,” Chapter 10.
Outcome variable:
IsCase—1=case; 0=control
Predictor variables:
Vaccine—1=vaccinated;0=not
Lung—1=underlying lung disease; 0=no underlying lung disease
Matching variable
Id—identifies each matching group (1 case, 2 controls)
2. Use point-and-click features to create a permanent library that points to the desktop (where the datasets are sitting):
a. Click on “new library” icon (slamming file cabinet on the toolbar).
b. Browse to find your desktop.
c. Name the library lab7.
d. Hit OK to exit and save.
3. Use your explorer browser to find the lab7 library and verify that you have a SAS dataset in there: matched.
4. Use the interactive data analysis features to check the variables in the dataset matched:
a. From the menu select: Solutions(Analysis(Interactive Data Analysis
b. Double click to open: library “lab7”, dataset “matched”
c. Highlight each variable from the menu select: Analyze(Distribution(Y)
d. What things do you notice?
e. What’s your sample size?
5. Run proc freq to view 2x2 tables:
proc freq;
tables iscase*lung iscase*vaccine /nocol nopct;
run;
iscase lung
Frequency‚
Row Pct ‚ 0‚ 1‚ Total
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
0 ‚ 252 ‚ 48 ‚ 300
‚ 84.00 ‚ 16.00 ‚
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
1 ‚ 87 ‚ 63 ‚ 150
‚ 58.00 ‚ 42.00 ‚
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
Total 339 111 450
Table of iscase by vaccine
iscase vaccine
Frequency‚
Row Pct ‚ 0‚ 1‚ Total
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
0 ‚ 183 ‚ 117 ‚ 300
‚ 61.00 ‚ 39.00 ‚
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
1 ‚ 103 ‚ 47 ‚ 150
‚ 68.67 ‚ 31.33 ‚
ƒƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆƒƒƒƒƒƒƒƒˆ
Total 286 164 450
6. Run the INCORRECT model, unconditional logistic regression, to see what happens:
proc logistic data = lab7.matched;
model iscase (event = "1") = lung vaccine /risklimits;
run;
Analysis of Maximum Likelihood Estimates
Standard Wald
Parameter DF Estimate Error Chi-Square Pr > ChiSq
Intercept 1 -0.9430 0.1444 42.6726 ................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related download
- sas regression using dummy variables
- logistic regression using sas university of michigan
- sas commands for logistic regression
- logistic regression
- differences between statistical software sas spss and
- building the regression model i selection of the
- logistic regression using sas
- practice problem for the final exam 3
- 20 stanford university
Related searches
- stanford university philosophy department
- stanford university plato
- stanford university encyclopedia of philosophy
- stanford university philosophy encyclopedia
- stanford university philosophy
- stanford university ein number
- stanford university master computer science
- stanford university graduate programs
- stanford university computer science ms
- stanford university phd programs
- stanford university phd in education
- stanford university online doctoral programs