Regression Analysis with the Ordered Multinomial Logistic Model Braden Hoelzle Southern Methodist University December 2009.

Slides:



Advertisements
Similar presentations
4-6 Arithmetic Sequences Warm Up Lesson Presentation Lesson Quiz
Advertisements

5.1 Rules for Exponents Review of Bases and Exponents Zero Exponents
Solving Quadratic Inequalities
3-2 Warm Up Lesson Presentation Lesson Quiz Using Algebraic Methods
Describing Data: Measures of Dispersion
Mean, Median, Mode & Range
Four Systems of Higher Education
Year 6 mental test 15 second questions Numbers and number system Numbers and the number system, Measures and Shape.
Overview of Lecture Parametric vs Non-Parametric Statistical Tests.
£1 Million £500,000 £250,000 £125,000 £64,000 £32,000 £16,000 £8,000 £4,000 £2,000 £1,000 £500 £300 £200 £100 Welcome.
1 What you've always wanted to know about logistic regression analysis, but were afraid to ask... Februari, Gerrit Rooks Sociology of Innovation.
Survival Analysis. Key variable = time until some event time from treatment to death time for a fracture to heal time from surgery to relapse.
Factoring Quadratics — ax² + bx + c Topic
Chapter 4: Basic Estimation Techniques
3/2003 Rev 1 I – slide 1 of 33 Session I Part I Review of Fundamentals Module 2Basic Physics and Mathematics Used in Radiation Protection.
Elementary Statistics
February Nature of the distribution is not known, or known to be non-normal. Sometimes called distribution free statistics Everything up to this.
Quantitative Methods II
2009 Foster School of Business Cost Accounting L.DuCharme 1 Determining How Costs Behave Chapter 10.
Polynomial Factor Theorem Polynomial Factor Theorem
2.5 Using Linear Models   Month Temp º F 70 º F 75 º F 78 º F.
Co-ordinate Geometry 1 Contents 1.Distance between points (Simple)Distance between points (Simple) 2.Pythagoras and Distance between two pointsPythagoras.
Statistical Analysis SC504/HS927 Spring Term 2008
7-1 Exponential Functions, Growth and Decay Warm Up
Chapter 16: Correlation. So far… We’ve focused on hypothesis testing Is the relationship we observe between x and y in our sample true generally (i.e.
Warm Ups {(2,0) (-1,3) (2,4)} Write as table Write as graph
Copyright © 2013 Pearson Education, Inc. All rights reserved Chapter 11 Simple Linear Regression.
Simple Linear Regression Analysis
Multiple Regression and Model Building
Chapter 16: Correlation.
Sociology 680 Multivariate Analysis Logistic Regression.
1 CAPM Betas The Capital Asset Pricing Model (“CAPM”) [ R s - R f ] = b 0 + b 1 [ R M - R f ] + e People commonly refer to the b 0 in this model as the.
SPH 247 Statistical Analysis of Laboratory Data. Generalized Linear Models The type of predictive model one uses depends on a number of issues; one is.
Brief introduction on Logistic Regression
- Word counts - Speech error counts - Metaphor counts - Active construction counts Moving further Categorical count data.
Multinomial Logistic Regression David F. Staples.
Analysis of Categorical Data Nick Jackson University of Southern California Department of Psychology 10/11/
ANOVA and Linear Models. Data Data is from the University of York project on variation in British liquids. Data is from the University of York project.
Copyright © Allyn & Bacon (2007) Data and the Nature of Measurement Graziano and Raulin Research Methods: Chapter 4 This multimedia product and its contents.
Logistic Regression Predicting Dichotomous Data. Predicting a Dichotomy Response variable has only two states: male/female, present/absent, yes/no, etc.
Nominal Level Measurement n numbers used as ways to identify or name categories n numbers do not indicate degrees of a variable but simple groupings of.
Ordinal Logistic Regression
Nemours Biomedical Research Statistics April 23, 2009 Tim Bunnell, Ph.D. & Jobayer Hossain, Ph.D. Nemours Bioinformatics Core Facility.
Relationships Among Variables
Unit 4c: Taxonomies of Logistic Regression Models © Andrew Ho, Harvard Graduate School of EducationUnit 4c – Slide 1
Chapter 12 Inferential Statistics Gay, Mills, and Airasian
Unit 4c: Taxonomies of Logistic Regression Models © Andrew Ho, Harvard Graduate School of EducationUnit 4c – Slide 1
Unit 4b: Fitting the Logistic Model to Data © Andrew Ho, Harvard Graduate School of EducationUnit 4b – Slide 1
MATH 3359 Introduction to Mathematical Modeling Project Multiple Linear Regression Multiple Logistic Regression.
Multiple Regression The Basics. Multiple Regression (MR) Predicting one DV from a set of predictors, the DV should be interval/ratio or at least assumed.
Chapter 20 For Explaining Psychological Statistics, 4th ed. by B. Cohen 1 These tests can be used when all of the data from a study has been measured on.
Copyright © 2014 McGraw-Hill Education. All rights reserved. No reproduction or distribution without the prior written consent of McGraw-Hill Education.
Forecasting Choices. Types of Variable Variable Quantitative Qualitative Continuous Discrete (counting) Ordinal Nominal.
Assessing Binary Outcomes: Logistic Regression Peter T. Donnan Professor of Epidemiology and Biostatistics Statistics for Health Research.
Regression. Types of Linear Regression Model Ordinary Least Square Model (OLS) –Minimize the residuals about the regression linear –Most commonly used.
Chapter 16 Data Analysis: Testing for Associations.
Université d’Ottawa - Bio Biostatistiques appliquées © Antoine Morin et Scott Findlay :32 1 Logistic regression.
CSE 5331/7331 F'07© Prentice Hall1 CSE 5331/7331 Fall 2007 Regression Margaret H. Dunham Department of Computer Science and Engineering Southern Methodist.
Logistic Regression and Odds Ratios Psych DeShon.
Beginners statistics Assoc Prof Terry Haines. 5 simple steps 1.Understand the type of measurement you are dealing with 2.Understand the type of question.
LOGISTIC REGRESSION. Purpose  Logistical regression is regularly used when there are only two categories of the dependent variable and there is a mixture.
BINARY LOGISTIC REGRESSION
A priori violations In the following cases, your data violates the normality and homoskedasticity assumption on a priori grounds: (1) count data  Poisson.
Logistic Regression APKC – STATS AFAC (2016).
Understanding Averages
Hypothesis Testing Review
Jeffrey E. Korte, PhD BMTRY 747: Foundations of Epidemiology II
What Else Is There?.
Introduction to Logistic Regression
Basic Introduction LOGISTIC REGRESSION
Presentation transcript:

Regression Analysis with the Ordered Multinomial Logistic Model Braden Hoelzle Southern Methodist University December 2009

Situating the Model GLM – Generalized Linear Model Linear RegressionLogistic Regression Ordered Multinomial Logistic Regression Unordered Multinomial Logistic Regression

Review: Logistic Regression Dichotomous Dependent Variable Independent Variables can be dichotomous, integral, categorical…etc. We are trying to predict the probability that a person does or doesnt have a trait Example: At risk of dropping out or Not at risk Others??

Transform to Probability Probability range = (0 p 1) Therefore we must transform continuous values to the range 0-1 by using the formula: Or expanded to:

A Quick Example > m1 <- glm(comply ~ physrec, family = binomial(link = "logit")) > summary(m1) Call: glm(formula = comply ~ physrec, family = binomial(link = "logit")) Coefficients: Estimate Std. Error z value Pr(>|z|) (Intercept) e-06 physrec e-07 The probability of complying if NOT recommended by physician: exp( )/(1 + exp( )) The probability of complying if recommended by physician: exp( )/(1 + exp( ))

Ordered Multinomial Logistic Model Four Types of Scales 1. _________ - mutually exclusive categories w/ no logical order. 2. _________ - mutually exclusive categories w/ logical rank order. 3. _________ - ordered data w/ equal distance between each point (no absolute zero). 4. _________ - ordered data w/ equal distance between each point (w/ a true zero). What type of data would you expect our ordered multinomial regression to model?

Definition The ordered multinomial logistic model enables us to model ordinally scaled dependent variables with one or more independent variables. These IV(s) can take many different forms (ie. real numbers values, integers, categorical, binomial, etc.).

Does this Occur Much? Ordinal data are the most frequently encountered type of data in the social sciences (Johnson & Albert, 1999, p. 126). Examples – Yes, maybe, no – Likert scale (Strongly Agree – Strongly Disagree) – Always, frequently, sometimes, rarely, never – No hs diploma, hs diploma, some college, bachelors degree, masters degree, doctoral degree – Free school lunch, reduced school lunch, full price lunch – 0-10k per year, 10-20K per year, 20-30K per year, 30 – 60K per year, > 60K per year – Low, medium, high – Basic math, regular math, pre-AP math, AP math – Neles dancing ability, Megs dancing ability, Saralyns dancing ability, Joses dancing ability, Kyles dancing ability, Bradens dancing ability, a rock

Running Regression using the Ordered Multinomial Logistic Model in R Load/Install Libraries: library(arm) library (psych) Load data (UCLA – Academic Technology Services, n.d.) mydata <- read.csv(url(" at/r/dae/ologit.csv")) attach(mydata)

Definitions Variables: apply - college juniors reported likelihood of applying to grad school (0 = unlikely, 1 = somewhat likely, 2 = very likely) pared – indicating whether at least one parent has a graduate degree (0 = no, 1 = yes) public – indicating whether the undergraduate institution is a pubic or private (0 = private, 1 = public) gpa – college gpa Which variable will likely be our dependent variable?

Description of Data > str(mydata) 'data.frame': 400 obs. of 4 variables: $ apply : int $ pared : int $ public: int $ gpa : num > summary(mydata$gpa) Min. 1st Qu. Median Mean 3rd Qu. Max > table(apply) apply > table(pared) pared > table(public) public

Crosstabs > xtabs(~ pared + apply) apply pared > xtabs(~ public + apply) apply public Why would this information be important for running our ordered multinomial logistic model?

Assumptions No perfect predictions – one predictor variable value cannot solely correspond to one dependent variable value. (ex. – Every student w/ parents who went to graduate school cannot indicate that they are very likely to attend graduate school) – check using crosstabs ( see slide 12). No empty or very small cells – see crosstabs. Sample Size – always requires more cases than OLS regression.

Running a Single Predictor Model > summary(m1 <- bayespolr(as.ordered(apply)~gpa,data=mydata)) Call: bayespolr(formula = as.ordered(apply) ~ gpa, data = mydata) Coefficients: Value Std. Error t value gpa Intercepts: Value Std. Error t value 0| | Residual Deviance: AIC:

Transforming Outcomes to Probabilities (beta <- coef(m1)) gpa (tau <- m1$zeta) 0|1 1| x<- 3 ##### Note: mean = logit.prob <- function(eta){exp(eta)/(1+exp(eta))} (p1 <- logit.prob(tau[1] - x * beta)) (p2<- logit.prob(tau[2] - x * beta) - logit.prob(tau[1] - x * beta)) (p3<- 1 - logit.prob(tau[2] - x * beta)) p1+p2+p3 1

Adding Multiple Predictors > summary(m2 <- bayespolr(as.ordered(apply)~gpa + pared + public,data=mydata)) Call: bayespolr(formula = as.ordered(apply) ~ gpa + pared + public, data = mydata) Coefficients: Value Std. Error t value gpa pared public Intercepts: Value Std. Error t value 0| | Residual Deviance: AIC:

Transforming Outcomes to Probabilities (beta <- coef(m2)) gpa pared public (tau <- m2$zeta) 0|1 1| (x<- cbind(0:4, 0,.15)) [,1] [,2] [,3] [1,] [2,] [3,] [4,] [5,] (x2<-cbind(0:4, 1,.15)) [,1] [,2] [,3] [1,] [2,] [3,] [4,] [5,]

Transforming Outcomes to Probabilities (cont.) logit.prob <- function(eta){exp(eta)/(1+exp(eta))} (p1 <- logit.prob(tau[1] - x %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,] (p2<- logit.prob(tau[2] - x %*% beta) - logit.prob(tau[1] - x %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,] (p3<- 1 - logit.prob(tau[2] - x %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,]

Transforming Outcomes to Probabilities (cont.) (p4 <- logit.prob(tau[1] - x2 %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,] (p5<- logit.prob(tau[2] - x2 %*% beta) - logit.prob(tau[1] - x2 %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,] (p6<- 1 - logit.prob(tau[2] - x2 %*% beta)) [,1] [1,] [2,] [3,] [4,] [5,]

Plotting the Results

Why Not Use Linear Regression? > summary(m1.2<-lm(apply~gpa, data=mydata)) Call: lm(formula = apply ~ gpa, data = mydata) Residuals: Min 1Q Median 3Q Max Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) gpa ** --- Signif. codes: 0 *** ** 0.01 * Residual standard error: on 398 degrees of freedom Multiple R-squared: , Adjusted R-squared: F-statistic: on 1 and 398 DF, p-value:

What Do Our Results Mean? Plug in a gpa of 3: > (y.hat<-( (.2568 * 3))) [1] This means that we expect someone w/ a 3.0 gpa to fall about half way between unlikely (0) and slightly likely (1) to apply to grad school. But what is half way between these two points (a little unlikely?, neither likely nor unlikely?, very slightly likely?) This is somewhat vague.

Our Graph using Linear Regression A Normal OLS Line An OLS Line on Our Data

We Royally Violate our Assumptions

However… The decision between linear regression and ordered multinomial regression is not always black and white. When you have a large number of categories that can be considered equally spaced simple linear regression is an optional alternative (Gelman & Hill, 2007). ** But check your assumptions!!

Practice Read in the following table (Quinn, n.d.): nes96 <- read.table(" es96r.dat", header=TRUE) Run a regression using the ordered multinomial logistic model to predict the variation in the dependent variable ClinLR using the dependent variables PID and educ. ClinLR = Ordinal variable from 1-7 indicating ones view of Bill Clintons political leanings, where 1 = extremely liberal, 2 = liberal, 3 = slightly liberal, 4 = moderate, 5= slightly conservative, 6 = conservative, 6 = extremely conservative. PID = Ordinal variable from 0-6 indicating ones own political identification, where 0 = Strong Democrat and 6 = Strong Republican educ = Ordinal variable from 1-7 indicating ones own level of education, where 1 = 8 grades or less and no diploma, 2 = 9-11 grades, no further schooling, 3 = High school diploma or equivalency test, 4 = More than 12 years of schooling, no higher degree, 5 = Junior or community college level degree (AA degrees), 6 = BA level degrees; 17+ years, no postgraduate degree, 7 = Advanced degree

References Gelman, A. & Hill, J. (2007). Data analysis using regression and multilevel/hierarchical models. New York: Cambridge University Press. Johnson, V. E. & Albert, J. H. (1999). Statistics for the social sciences and public policy: Ordinal data modeling. New York: Springer. Quinn, K. (n.d.). Retrieved from asses/536/data/nes96r.dat UCLA: Academic Technology Services. (n.d.). Retrieved from at/r/dae/ologit.csv