GRA 5917: Input Politics and Public Opinion: Panel Data Regression in Political Economy
GRA 5917: Input Politics and Public Opinion: Panel Data Regression in Political Economy
GRA 5917 Public Opinion and Input Politics. Lecture September 16h 2010
First, though: A short note on logistic regression (from last
week)…
0.9
0.8
0.7
0.6
P 0.5
0.4
0.3
0.2
0.1
L(X)
Logistic regression
Choose Binary
logistic
Logistic regression in SPSS
Choose dependent
variable
Choose reference
category, i.e. to
model P(not in ref.
category)
Logistic regression in SPSS
Choose predictors:
class variables
(factors) or
contiuous variables
(covariates)
Logistic regression in SPSS
Build model
Presenting changes in P(y=1) from logistic regression
results
Have estimated L=0.4+1.2·X for X ranging from -4 to 10
Presenting changes in P(y=1) from logistic regression
results
Have estimated L=0.4+1.2·X for X ranging from -4 to 10
Excercises (I)
a) You are interested in how people’s age influences their general feeling of happiness.
Use the XWVSEVS_1981_2000_v20060423.sav data set supplied under the PolEc
Dataset folder on It’s Learning.
a) Create a new variable happy that takes on the value 1 if the individual in
question reports to be happy (’very’ or ’quite’) and 0 otherwise. Run a simple
binary logistic regression with happy as dependent variable and (continous) age
(x003) and the indivual’s houshold income (x047) as independent variables.
Comment on the results and graph the realtionship between the probability of
being happy and age (Tip: Use descriptive analysis to find the minimum and
maximum of age, i.e. the range for which reasonable predictions of happiness
can be made, and graph the relationship holding income level constant at the
mean).
b) Redo the analysis with year of birth (x003) added to the model. Comment on the
results in the SPSS output and again graph the relationship between age and the
probability of being happy (holding both year of birth and income cosntant at
their respective means).
Analysis of panel data
A time-invariant covariate…
• Given the correct model…
k 1
will give unbiased estimates of bA: the Dk exhaust varaiation between
cross–section units (i); i.e. influence from all observable and
unobservable time-invariant variables are accounted for
Analysis of panel data in SPSS (I)
OLS regression with country specific (and time specific) dummy variables added to
the equation (as independent variables) with Analyze > Regression > Linear…
problem: How create a large set of dummy variables?
Or use the mixed models feature: Analyze > Mixed Models > Linear…
(Maximum Likelihood estimation); creates group dummies from class
variables automatically
Analysis of panel data in SPSS (II)
Click Continue
Analysis of panel data in SPSS (II)
Move the
dependent
variable into
Dependent frame
and class
independents into
Factor(s) and
continuous
independents into
Covariate(s);
choose REML
estimation under
Estimation… and
Parameter
Estimates under
Statistics…
Analysis of panel data in SPSS (II)
Click Fixed…
Analysis of panel data in SPSS (II)
Mark variables
that will appear in
the Factors and
Covariates frame
and Add them to
the Model frame.
Click Continue
Analysis of panel data in SPSS (II)
Click OK to start
analysis
A note on within R2
(Residual Model with group effects only – Residual Full Model)/ Residual Model with group effects only
i.e. the proprortion of explainable variance (after group effects have been taken into
account) that is explained by variables varying within groups
Analysis of panel data (II)…
k 1
…one could estimate the random effects model
Click Random
and build random
terms in same
way as you would
build fixed terms
Excercises (II)