C. Logit model, logistic regression, and log-linear model A comparison.

Slides:



Advertisements
Similar presentations
Individual level synthetic regression models Session 4.
Advertisements

Chapter 2 Describing Contingency Tables Reported by Liu Qi.
Sociology 680 Multivariate Analysis Logistic Regression.
Lecture 11 (Chapter 9).
© Department of Statistics 2012 STATS 330 Lecture 32: Slide 1 Stats 330: Lecture 32.
Multinomial Logistic Regression David F. Staples.
The Analysis of Categorical Data. Categorical variables When both predictor and response variables are categorical: Presence or absence Color, etc. The.
Logistic Regression Example: Horseshoe Crab Data
Loglinear Models for Contingency Tables. Consider an IxJ contingency table that cross- classifies a multinomial sample of n subjects on two categorical.
Logistic Regression Multivariate Analysis. What is a log and an exponent? Log is the power to which a base of 10 must be raised to produce a given number.
Models of migration Observations and judgments In: Raymer and Willekens, 2008, International migration in Europe, Wiley.
Multinomial Logistic Regression
Log-linear modeling and missing data A short course Frans Willekens Boulder, July
Linear statistical models 2008 Count data, contingency tables and log-linear models Expected frequency: Log-linear models are linear models of the log.
(Correlation and) (Multiple) Regression Friday 5 th March (and Logistic Regression too!)
1 G Lect 11M Binary outcomes in psychology Can Binary Outcomes Be Studied Using OLS Multiple Regression? Transforming the binary outcome Logistic.
Linear statistical models 2009 Count data  Contingency tables and log-linear models  Poisson regression.
Log-linear analysis Summary. Focus on data analysis Focus on underlying process Focus on model specification Focus on likelihood approach Focus on ‘complete-data.
Generalized Linear Models
1 B. The log-rate model Statistical analysis of occurrence-exposure rates.
Log-linear modeling and missing data A short course Frans Willekens Boulder, July-August 1999.
Logistic regression for binary response variables.
Logistic Regression Logistic Regression - Dichotomous Response variable and numeric and/or categorical explanatory variable(s) –Goal: Model the probability.
AS 737 Categorical Data Analysis For Multivariate
LIS 570 Summarising and presenting data - Univariate analysis continued Bivariate analysis.
Occurrence and timing of events depend on Exposure to the risk of an event exposure Risk depends on exposure.
Biostatistics Case Studies 2005 Peter D. Christenson Biostatistician Session 4: Taking Risks and Playing the Odds: OR vs.
Logit model, logistic regression, and log-linear model A comparison.
ALISON BOWLING THE GENERAL LINEAR MODEL. ALTERNATIVE EXPRESSION OF THE MODEL.
A. Analysis of count data
April 6 Logistic Regression –Estimating probability based on logistic model –Testing differences among multiple groups –Assumptions for model.
Introduction to Logistic Regression Rachid Salmi, Jean-Claude Desenclos, Alain Moren, Thomas Grein.
University of Warwick, Department of Sociology, 2014/15 SO 201: SSAASS (Surveys and Statistics) (Richard Lampard) Week 7 Logistic Regression I.
April 4 Logistic Regression –Lee Chapter 9 –Cody and Smith 9:F.
Forecasting Choices. Types of Variable Variable Quantitative Qualitative Continuous Discrete (counting) Ordinal Nominal.
Categorical Data Analysis: Logistic Regression and Log-Linear Regression 26 Nov 2010 CPSY501 Dr. Sean Ho Trinity Western University For discussion: Myers.
Advanced statistics for master students Loglinear models.
Assessing Binary Outcomes: Logistic Regression Peter T. Donnan Professor of Epidemiology and Biostatistics Statistics for Health Research.
Copyright © 2006 The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Dummy Variable Regression Models chapter ten.
Logistic regression. Recall the simple linear regression model: y =  0 +  1 x +  where we are trying to predict a continuous dependent variable y from.
Joyful mood is a meritorious deed that cheers up people around you like the showering of cool spring breeze.
Warsaw Summer School 2015, OSU Study Abroad Program Advanced Topics: Interaction Logistic Regression.
1 STA 617 – Chp10 Models for matched pairs Summary  Describing categorical random variable – chapter 1  Poisson for count data  Binomial for binary.
Log-linear Models HRP /03/04 Log-Linear Models for Multi-way Contingency Tables 1. GLM for Poisson-distributed data with log-link (see Agresti.
1 Everyday is a new beginning in life. Every moment is a time for self vigilance.
1 Topic 4 : Ordered Logit Analysis. 2 Often we deal with data where the responses are ordered – e.g. : (i) Eyesight tests – bad; average; good (ii) Voting.
Logistic Regression. Linear regression – numerical response Logistic regression – binary categorical response eg. has the disease, or unaffected by the.
Statistics 2: generalized linear models. General linear model: Y ~ a + b 1 * x 1 + … + b n * x n + ε There are many cases when general linear models are.
Logistic regression (when you have a binary response variable)
1 Introduction to Modeling Beyond the Basics (Chapter 7)
University of Warwick, Department of Sociology, 2012/13 SO 201: SSAASS (Surveys and Statistics) (Richard Lampard) Logistic Regression II/ (Hierarchical)
Logistic Regression and Odds Ratios Psych DeShon.
Nonparametric Statistics
Employment Sorting by Size: The Role of Health Insurance Lan Liang and Barbara Schone.
Quantitative Research Methods for Social Sciences Spring 2012 Module 2: Lecture 7 Introduction to Generalized Linear Models, Logistic Regression and Poisson.
ERIC CANEN, M.S. UNIVERSITY OF WYOMING WYOMING SURVEY & ANALYSIS CENTER EVALUATION 2010: EVALUATION QUALITY SAN ANTONIO, TX NOVEMBER 13, 2010 What Am I.
Nonparametric Statistics
University of Warwick, Department of Sociology, 2014/15 SO 201: SSAASS (Surveys and Statistics) (Richard Lampard) Logistic Regression II/ (Hierarchical)
Advanced Quantitative Techniques
Generalized Linear Models
Introduction to logistic regression a.k.a. Varbrul
Wildlife Population Analysis What are those βs anyway?
Nonparametric Statistics
Categorical Data Analysis Review for Final
The log-rate model Statistical analysis of occurrence-exposure rates
Introduction to Logistic Regression
Introduction to log-linear models
Joyful mood is a meritorious deed that cheers up people around you
Presentation transcript:

C. Logit model, logistic regression, and log-linear model A comparison

Leaving home Models of counts: log-linear model

Leaving home

 11 = exp[4.697] =  21 = exp[ ] =  12 = exp[ ] = 99.4  22 = exp[ ]= Model 3: Time and Sex (unsaturated log-linear model) Leaving home

Model 4: TIME AND SEX AND TIME*SEX interaction  11 = exp[4.905= 135  21 = exp[ ] = 143  12 = exp[ ] = 74  22 = exp[ ]= 178 Leaving home

Log-linear and logit model

Log-linear model: Select one variable as a dependent variable: response variable, e.g. does voting behaviour differ by sex Are females more likely to vote conservative than males? Logit model: Political attitudes

Males voting conservative rather than labour: Females voting conservative rather than labour: Are females more likely to vote conservative than males? Log-odds = logit Effect coding (1) A = Party; B = Sex Political attitudes

Are women more conservative than men? Do women vote more conservative than men? The odds ratio. If the odds ratio is positive, then the odds of voting conservative rather than labour is larger for women than men. In that case, women vote more conservative than men. Logit model: with a = and b = Log odds of reference category (males) Log odds ratio (odds females / odds males) with x = 0, 1 Political attitudes

The logit model as a regression model

Select a response variable  proportion Dependent variable of logit model is the log of (odds of) being in one category rather than in another. Number of observations in each subpopulation (males, females) is assumed to be fixed. Intercept (a) = log odds of reference category Slope (b) = log odds ratio

DATA Sex Party Male Female Total Conservative Labour Total Logit model: descriptive statistics Counts in terms of odds and odds ratio Reference categories: Labour; Males F 11 = 279 F 21 = 335 = 279 * 335/279 = 279 / F 12 = 352 = 279 * 352/279 = F 22 = 291 = 279 * 352/279 * 291/352 = 279 * * [1/1.2096] Political attitudes

Logistic regression SPSS Variable Param S.E. Exp(param) SEX(1) Constant Females voting labour: 1/[1+exp[-( )]] = 45%  291/626 (females ref.cat) Males voting labour: 1/[1+exp[-( )]] = 55%  335/626 Reference category: females (X = 1 for males and X = 0 for females) Different parameter coding: X = -0.5 for males and X = 0.5 for females Variable Param S.E. Exp(param) SEX(1) Constant Females voting labour: 1/[1+exp[-( *( ))]] = 45%  291/626 Males voting labour: 1/[1+exp[-( * ( ))]] = 55%  335/626 Political attitudes

Observation from a binomial distribution with parameter p and index m The logit model and the logistic regression Leaving parental home

Leaving Home

Leaving home

Relation logit and log-linear model The unsaturated model Log-linear model: With  i effect of timing and  j effect of sex Odds of leaving parental home late rather than early: females: Leaving home

Relation logit and log-linear model The unsaturated model Odds of leaving parental home late rather than early: males: Leaving home

Relation logit and log-linear model The saturated model Log-linear model: With  i effect of timing and  j effect of sex and  ij the effect of interaction between timing and sex Odds of leaving parental home late rather than early: females (ref): Leaving home

Relation logit and log-linear model The saturated model Odds of leaving parental home late rather than early: males: Leaving home

Logit model: Logistic regression: probability of leaving home late X=0 for males X=1 for females Leaving home

Dummy coding: ref.cat: females, late Effect coding or marginal coding: females +1; males –1 Leaving home

The logistic regression in SPSS Micro data and tabulated data

SPSS: Micro-data Micro-data: age at leaving home in months Crosstabs: Number leaving home by reason (row) and sex (column) Create variable: Age in years Age = TRUNC[(month-1)/12] Create variable: TIMING2 based on MONTH : TIMING2 =1 (early) if month  240 & reason < 4 TIMING2 =2 (late) if month > 240 & reason < 4 For analysis: select cases that are NOT censored: SELECT CASES with reason < 4

SPSS: tabulated data Number of observations: WEIGHT cases (in data) No difference between model for tabulated data and micro-data

The logistic regression in SPSS Leaving home

Related models Poisson distribution: counts have Poisson distribution (total number not fixed) Poisson regression Log-linear model: model of count data (log of counts) Binomial and multinomial distributions: counts follow multinomial distribution (total number is fixed) Logit model: model of proportions [and odds (log of odds)] Logistic regression Log-rate model: log-linear model with OFFSET (constant term) Parameters of these models are related