1 chapter 2: logistic regression and correspondence analysis 2.1 fitting ordinal logistic regression...

40
1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models 2.3 Introduction to Correspondence Analysis

Upload: randall-owen

Post on 14-Dec-2015

231 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

1

Chapter 2: Logistic Regression and Correspondence Analysis

2.1 Fitting Ordinal Logistic Regression Models

2.2 Fitting Nominal Logistic Regression Models

2.3 Introduction to Correspondence Analysis

Page 2: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2

Chapter 2: Logistic Regression and Correspondence Analysis

2.1 Fitting Ordinal Logistic Regression Models2.1 Fitting Ordinal Logistic Regression Models

2.2 Fitting Nominal Logistic Regression Models

2.3 Introduction to Correspondence Analysis

Page 3: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Objectives Define a cumulative logit. Fit an ordinal logistic regression model. Interpret parameter estimates. Compute odds ratios.

3

Page 4: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

When Do You Use Ordinal Logistic Regression?

4

Nominal

Ordinal

BinaryTwo

Categories

Threeor More

Categories

Response VariableType of

Logistic Regression

Binary

Nominal

Ordinal

Yes No

Page 5: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Cumulative Logits

5

Response

Log

Log

Logit(1)

Logit(2)

Number of Cumulative Logits = Number of Levels -1

Page 6: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Proportional Odds Assumptions

6

Predictor X

Logit(i) Logit(2)= a2+BX

Logit(1)= a1+BX

Equal Slopes

Page 7: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Sample Data Set

7

PREDICTORS

OUTCOME

>100

75-100

50-74

25-49

0-24

5

4

3

2

1

Gender

Income

Age

MODEL

Page 8: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

8

This demonstration illustrates the concepts discussed previously.

Examining Distributions

Page 9: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

9

Page 10: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

10

Exercise

This exercise reinforces the concepts discussed previously.

Page 11: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

11

Chapter 2: Logistic Regression and Correspondence Analysis

2.1 Fitting Ordinal Logistic Regression Models

2.2 Fitting Nominal Logistic Regression Models2.2 Fitting Nominal Logistic Regression Models

2.3 Introduction to Correspondence Analysis

Page 12: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Objectives Explain a generalized logit. Fit a nominal logistic regression model. Interpret the parameter estimates. Compute odds ratios.

12

Page 13: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

When To Use Nominal Logistic Regression?

13

Nominal

Ordinal

BinaryTwo

Categories

Threeor More

Categories

Response VariableType of

Logistic Regression

Binary

Nominal

Ordinal

Yes No

Page 14: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Generalized Logits

14

Response

Log

Log

Logit(1)

Logit(2)

Number of Generalized Logits = Number of Levels -1

Page 15: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Generalized Logit Model

15

Logit(i)

Predictor X

Different Slopes and

Intercepts

Logit(i)

Predictor X

Logit(2)=a2+B2X

Logit(1)=a1+B1X

Different Slopesand

Intercepts

Page 16: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models
Page 17: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2.01 Multiple Choice PollSuppose a nominal response variable has four levels. Which of the following statements is true?

a. JMP will compute three generalized logits.

b. Logit(1) is the log odds for level 1 occurring versus level 4 occurring.

c. JMP will compute a separate intercept parameter for each logit.

d. JMP will compute a separate slope parameter for each logit.

e. All of the above are true.

17

Page 18: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2.01 Multiple Choice Poll – Correct AnswerSuppose a nominal response variable has four levels. Which of the following statements is true?

a. JMP will compute three generalized logits.

b. Logit(1) is the log odds for level 1 occurring versus level 4 occurring.

c. JMP will compute a separate intercept parameter for each logit.

d. JMP will compute a separate slope parameter for each logit.

e. All of the above are true.

18

Page 19: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Sample Data Set

19

PREDICTORS

OUTCOME

>100

75-100

50-74

25-49

0-24

5

4

3

2

1

Gender

Income

Age

MODEL

Page 20: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

20

This demonstration illustrates the concepts discussed previously.

Nominal Logistic Regression Model

Page 21: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

21

Page 22: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

22

Exercise

This exercise reinforces the concepts discussed previously.

Page 23: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

23

Chapter 2: Logistic Regression and Correspondence Analysis

2.1 Fitting Ordinal Logistic Regression Models

2.2 Fitting Nominal Logistic Regression Models

2.3 Introduction to Correspondence Analysis2.3 Introduction to Correspondence Analysis

Page 24: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Objectives Explain how correspondence analysis can help

you study data. Perform a simple correspondence analysis. Interpret a correspondence plot.

24

Page 25: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

What Is Correspondence Analysis?Correspondence analysis is a data analysis technique that enables you to display the associations between the levels of two

or more categorical variables graphically extract information from a frequency table with

many levels for the rows and columns.

25

Page 26: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Row and Column Profiles

Row and column percentages are used to obtain row and column profiles.

26

A B C

1

4

19.5527.39

25.9123.27

54.5525.53

217.2724.20

28.84

29.49

25.31

26.12

53.49

53.00

24.47

24.47

317.6724.20

17.5124.20

28.1825.31

54.5525.53

GivesRow Profile

Gives Column Profile

Row %Column %

Page 27: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Row Profiles

Row percentages are used to obtain row profiles.

27

A B C

1

4

19.55 25.91 54.55

2 17.27

28.84

29.49

53.49

53.00

3 17.67

17.51

28.18 54.55

Row %

Row Profile = Row%/100

Page 28: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Column Profiles

Column percentages are used to obtain column profiles.

28

A B C

1

4

27.39 23.27 25.53

2 24.20

25.31

26.12

24.47

24.47

3 24.20

24.20

25.31 25.53

Column %

Col Profile = Column%/100

Page 29: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Rows 1 and 2 have similar profiles. Their points are close together and fall in the same direction away from the origin.

The profile for Row 7 is different. Its point is closer in and falls in a different direction away from the origin.

Correspondence Plot

29

Page 30: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Row 8 and Column D fall in approximately the same direction from the origin, and are relatively close to one another.

Association

30

Page 31: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models
Page 32: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2.02 Multiple Answer PollIn correspondence analysis, which of the following are true? (Choose all answers that apply.)

a. Row points that fall far from each other but in the same direction away from the origin indicate that they have similar profiles.

b. Column points that fall close together and in the same direction away from the origin indicate that they have similar profiles.

c. Row and column points that fall in the same direction away from the origin indicate that they have an association.

32

Page 33: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2.02 Multiple Answer Poll – Correct AnswersIn correspondence analysis, which of the following are true? (Choose all answers that apply.)

a. Row points that fall far from each other but in the same direction away from the origin indicate that they have similar profiles.

b. Column points that fall close together and in the same direction away from the origin indicate that they have similar profiles.

c. Row and column points that fall in the same direction away from the origin indicate that they have an association.

33

Page 34: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Sample Data Set

34

ACTION

MYSTERY

COMEDY

SPORTS

ROMANCE

SCI-FI

HORROR

DRAMA

FAMILY

AGE

GENDER

MOVIES

Page 35: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

Analysis ApproachesYou want to perform an analysis that takes into account the three variables Movie, Age, and Gender. There are several approaches. You can analyze a two-way table where the rows correspond

to the levels of Movie and the columns correspond to combinations of the levels of Age and Gender

treat Gender as a stratification variable and analyze males and females separately.

35

Page 36: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

36

This demonstration illustrates the concepts discussed previously.

Correspondence Analysis

Page 37: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

37

Page 38: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

38

Exercise

This exercise reinforces the concepts discussed previously.

Page 39: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models
Page 40: 1 Chapter 2: Logistic Regression and Correspondence Analysis 2.1 Fitting Ordinal Logistic Regression Models 2.2 Fitting Nominal Logistic Regression Models

2.03 QuizIce cream brands A through D are tested by a panel, and rated from 1through 9 (with 9 as the best score). What can you conclude from the Correspondence Analysis?

40