Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: cross-sectional dependence in panels - Pesaran test

From   "R.E. De Hoyos" <>
To   <>
Subject   st: Re: cross-sectional dependence in panels - Pesaran test
Date   Fri, 9 Jun 2006 13:37:13 +0100

Dear Krishna,

Me and Vasilis Sarafidis wrote a Stata command (-xtcsd-) with Pesaran's CD test and other popular tests for cross sectional dependence in panel data models. We also wrote an article explaining the way in which the command -xtcsd- works. At the moment the command and the paper are under revision of the Stata Journal editors.

We are planning to send the command to SSC archives shortly (next week), however since you are desperate, write to me privately ( and I will email you the command and help file.

All the best,

Rafael E. De Hoyos
Faculty of Economics
University of Cambridge

----- Original Message ----- From: "Krishna Naidoo" <>
To: <>
Sent: Friday, June 09, 2006 12:28 PM
Subject: st: cross-sectional dependence in panels - Pesaran test

Dear Statalist

I have an unbalanced panel with N>t. I need to test
for cross-sectional dependence. I tried using xttest2
but it gave an error code, presumably because of the
N>t issue:
__000002 not found

I would thus like to implement the Pesaran test for
cross-sectional dependence in a panel. A previous
posting by Vasilis Sarafidis

indicated that
"If you mean testing for cross-sectional correlation
in a panel with N > T, there is a recent paper by
Hashem Pesaran, which is easy to read and you can do
the calculations within 5 minutes in Stata. See";

I have looked at the paper but really do not
understand how to go about implementing the test in
practice. I gather that one needs to constuct a
correlation matrix from the residuals and somehow sum
up the elements of the martrix. But can anyone explain
to me in a very simple step-by-step way, preferably
with an example of some code (assuming no user-written
program already exists for this) how to implement this
test in practice? I have really tried working it out
myself and simply dont know how to proceed. I have
never worked with matrices in Stata before and am a
bit desperate!

Many thanks
Krishna Naidoo

Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
*   For searches and help try:

*   For searches and help try:

© Copyright 1996–2023 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index