POLMETH Archives

Political Methodology Society

POLMETH@LISTSERV.WUSTL.EDU

Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Manoel Neto <[log in to unmask]>
Reply To:
Political Methodology Society <[log in to unmask]>
Date:
Fri, 12 Dec 2008 11:05:18 -0800
Content-Type:
text/plain
Parts/Attachments:
text/plain (285 lines)
Hello all,
I am having a problem with a package in R and I was wondering if anyone can help me.

I am running gee in R to fit a model and it gives me an error. My dependent variable is a dichotomous one, coded 1 if an international treay is in force that year for a country, 0 otherwise. I am regressing it for per capita income and regime (democracy or autocracy). I intend to use other regressors in a nearby future.

Anyway, when I run gee using AR-M, M=1, it gives me an error message:
 "VC_GEE_covlag: arg has > MAX_COVLAG rows"


 I have observations for 186 countries, for 58 years. Does anyone know if there is a maximum to the cluster size? Could this be the problem (since my cluster are countries, with size 58) with gee? Any help? Any advice?

I am using GEE to correct for correlated dependent variable.

Thanks in advance,

Manoel Galdino
Phd student of Political Science at Universidade de São Paulo, Brasil.


Manoel Galdino Pereira Neto


http://prafalardecoisas.wordpress.com
www.aepidemia.org
http://ecourbana.wordpress.com
www.caeni.com.br




________________________________
De: "Franzese, Robert" <[log in to unmask]>
Para: [log in to unmask]
Enviadas: Quinta-feira, 11 de Dezembro de 2008 5:52:46
Assunto: Re: [POLMETH] spatial dependence of observations

Helen,

Probably much longer than you or anyone else could have wanted, but some
hopefully helpful thoughts & comments:

First, Mark is very kind to note Jude Hays's and my PA article.

Second, the Driscoll-Kraay estimator toward which he points you is
essentially PCSE (oddly, they do not cite the Beck & Katz pieces that
precede their, more technical, article...but then again, that's not odd
for economists to ignore political scientists who precede them...). As
Mark says, if you've no substantive interest in the (inter)dependence,
this might be an acceptable option, under some conditions (see below).

Antonio is also very helpful to point you toward Michael Ward & Kristian
Gleditsch's sage volume on Spatial Regression Models. It's a wonderful
and wonderfully accessible and useful intro.

You might also want to see our chapter in the Oxford Handbook of
Political Methodology, as it has a bit on testing, bottom up or top
down, for the various forms (spatial lag or spatial error) in which
spatial interdependence may arise. (Ward & Gleditsch have the same and a
bit more on diagnostics and pre-tests for you, and they have much more
on mapping and exploratory analysis than we do as well.)

You might instead prefer our more recent article in Comparative
Political Studies, which discusses more the substance and passes over
quickly and/or relegates to web appendix the more technical aspects.
More practically, there you will also find reference to the following:
Data, Code, & Template Implementation Files
<http://www.umich.edu/~franzese/FranzeseHays.CPS.InterdependenceCP.Templ
ateImplementationFiles.zip> (Contains: Stata code for
spatial-autoregressive-model estimation by maximum likelihood; Stata
code for calculating spatial dynamics, effects, and standard errors;
Lotus 1-2-3 *.wk1 files of data and contiguity matrix; MatLab code for
reanalysis of this paper's estimations.)

As you do not say anything about the substantive context or model in
which you expect some spatial dependence in your TSCS data, it is
difficult to know how to advise you about what sort of model and
estimator you need. That is, spatial _correlation_ can arise from
multiple different sources (2 or 4, depending on how you count--there's
a 3rd possibility, or 5th & 6th, that's more complex to explain from
this perspective but would be familiar to network analysts as
'selection' effects, such as 'homophily'), each of which has different
statistical implications, and only some of which are spatial
(inter)dependence, a.k.a. contagion:

1. Exposure to common or correlated exogenous external conditions or
correlation in the exogenous internal conditions.
    1a. These may be observable external or internal conditions, in
which case the best strategy is, as usual, properly to include these
exogenous external or internal X's that are the source of the spatial
correlation in your properly specified model. I.e., have a good model of
E(y). Obviously, if/insofar as you omit these, you will have omitted
variable bias.
    1b. These may instead (or also) be unobservable exogenous
external or internal conditions, in which case you may want some sort of
spatial error-components model, and/or fixed or random (_time_, not
unit) effects, & the like (hierarchical/multilevel models, e.g.). This
is also the case to which PCSE/Driscoll-Kraay might best apply.

2. Outcomes (or, similarly but not identically, expected outcomes or
unit internal factors (X's)) of some units affect outcomes in other
units. Again, this may be in unobservables, namely in the stochastic
components, or in observables, the outcomes themselves (or expected
outcomes or unit internal factors (X's)). This is interdependence.
    2a. If contagion occurs in the unobserved stochastic component
only, then OLS is unbiased and consistent but inefficient and its
standard errors are just plain wrong (just like in the serially
correlated or hetero-skedastic residuals case). In this case, again,
something Beck-Katz/Driscoll-Kraay like might be an option, but if you
cared substantively about the interdependence, you'd want to estimate a
spatial error model, so you could talk about diffusion of shocks and the
like, and also to gain the efficiency & not just render your standard
errors consistent in the presence of spatial correlation. But situations
where one expects contagion in the stochastic component only might be
rare (seem so to us).
    2b. If contagion occurs in the outcome, y, then you want a
spatial-lag model, or, in the TSCS case, the spatiotemporal-lag model.
We discuss the spatiotemporal-lag model (derivation of its likelihood is
due to Elhorst, as Mark noted). You can use our MatLab code (built from
LeSage's, by the way), or rework our stata template for your
implementation, or you could, if you believe its necessary conditions
that we discuss in the Hndbk piece, try the simplest strategy, which is
to estimate by OLS or something like it using a time-lagged spatial-lag
(as Beck & Gleditsch & Beardsley suggest may work well enough in some
instances & can be tested). Oh, one other intermediate-difficulty
option: you can use instrumental variables (2SLS) with the instruments
we talk about in those pieces (or the GMM version if you want to get
fancy & squeeze more efficiency--the instrumental-variable stuff is
mostly due to Kelijian & Prucha). In the contagion case, i.e., where
outcomes in some units depend on those in others, any of the strategies
that avoid modeling the interdependence (like OLS with or without PCSE,
like error-components approaches, like any of a number of fancy or
super-fancy statistical pre-filtering strategies I didn't describe here)
are especially bad ideas. Plainly: you'll simply have the wrong
substance model--the substance is spatially or spatiotemporally dynamic
and you'll have estimated something that is not dynamic. 

Hope this helps,
(Apologies for droning on so, a subject of some interest to me...)
Rob

*********************************************
        Robert (Rob) J. Franzese, Jr.
Professor, Department of Political Science,
   and Research Professor, C.P.S., I.S.R.,
    The University of Michigan, Ann Arbor
---------------------------------------------
   Room 4246 Institute for Social Research
P.O. Box 1248 (for courier: 426 Thompson St.)
           Ann Arbor, MI 48106-1248
office: 1-734-936-1850; fax: 1-734-764-3341
  http://www-personal.umich.edu/~franzese
*********************************************

-----Original Message-----
From: Political Methodology Society [mailto:[log in to unmask]] On
Behalf Of Mark S. Manger
Sent: Wednesday, December 10, 2008 4:07 PM
To: [log in to unmask]
Subject: Re: [POLMETH] spatial dependence of observations

PCSE doesn't address the issue of spatial dependence at all. Worth  
reading is definitely: Franzese, Robert J., Jr., and Jude C. Hays.  
2007. "Spatial econometric models of cross-sectional interdependence  
in political science panel and time-series-cross-section data."  
Political Analysis 15 (2):140-64.

The TSCS data makes this a bit tricky, but I see two relatively  
unproblematic options:

-- if you're not interested in spatial dependence as a causal factor,  
you could use the Driscoll-Kraay estimator, implemented in Stata as  
the downloadable module xtscc


@article{DriscollConsistent1998,
    Author = {Driscoll, John C. and Kraay, Aart C.},
    Date-Added = {2008-10-07 14:28:07 -0400},
    Date-Modified = {2008-10-07 14:28:13 -0400},
    Doi = {10.1162/003465398557825},
    Eprint =
{http://www.mitpressjournals.org/doi/pdf/10.1162/003465398557825 
},
    Journal = {Review of Economics and Statistics},
    Number = {4},
    Pages = {549--560},
    Title = {Consistent Covariance Matrix Estimation with Spatially

Dependent  Panel Data},
    Url = {http://www.mitpressjournals.org/doi/abs/ 
10.1162/003465398557825},
    Volume = {80},
    Year = {1998},
    Bdsk-Url-1 =
{http://www.mitpressjournals.org/doi/abs/10.1162/003465398557825 
},
    Bdsk-Url-2 = {http://dx.doi.org/10.1162/003465398557825}}

-- if you care about spatial dependence in its own right, you should  
have a look at 

Elhorst, J. Paul. 2003. "Specification and estimation of spatial panel  
data models." International Regional Science Review 26 (3):244-68.

Running those models requires Matlab, but it's not hard.

--Mark

Mark S. Manger, PhD
Assistant Professor
Department of Political Science
McGill University
[log in to unmask]
Phone 514-398-8971

On 10-Dec-08, at 2:56 PM, Helen Brown wrote:

>>
>> Hello,
>>
>> What can be done, within the OLS framework, to address the issue of  
>> spatial
>> dependence in TSCS data?
>> Shall I go for PCSEs, instead?
>>
>> Cheers,
>> Helen
>>
>
> **********************************************************
>             Political Methodology E-Mail List
>   Editors: Melanie Goodrich, <[log in to unmask]>
>            Delia Bailey, <[log in to unmask]>
> **********************************************************
>        Send messages to [log in to unmask]
>  To join the list, cancel your subscription, or modify
>           your subscription settings visit:
>
>          http://polmeth.wustl.edu/polmeth.php
>
> **********************************************************

**********************************************************
             Political Methodology E-Mail List
   Editors: Melanie Goodrich, <[log in to unmask]>
            Delia Bailey, <[log in to unmask]>
**********************************************************
        Send messages to [log in to unmask]
  To join the list, cancel your subscription, or modify
           your subscription settings visit:

          http://polmeth.wustl.edu/polmeth.php

**********************************************************

**********************************************************
             Political Methodology E-Mail List
   Editors: Melanie Goodrich, <[log in to unmask]>
            Delia Bailey, <[log in to unmask]>
**********************************************************
        Send messages to [log in to unmask]
  To join the list, cancel your subscription, or modify
           your subscription settings visit:

          http://polmeth.wustl.edu/polmeth.php

**********************************************************



      Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com

**********************************************************
             Political Methodology E-Mail List
   Editors: Melanie Goodrich, <[log in to unmask]>
            Delia Bailey, <[log in to unmask]>
**********************************************************
        Send messages to [log in to unmask]
  To join the list, cancel your subscription, or modify
           your subscription settings visit:

          http://polmeth.wustl.edu/polmeth.php

**********************************************************

ATOM RSS1 RSS2