Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Testing for autocorrelation after clustering?

    Hi all,

    I've got panel data and I'm running a FE model clustering on my panel variable (companies). (47 Companies, 1577 observations, so smaller average T than N)

    Before clustering, I thought I should test for autocorrelation, however, since there are gaps in my time series, xtserial reported back: r(2000) "no observations." Even though I can't test for autocorrelation, given my data (historical individual company records) I think it's likely that there is autocorrelation. To account for this, I decided to cluster thinking that the worst case scenario would be that my standard errors are too conservative. I have two questions about this:

    1. Is there a way to test for autocorrelation in my clustered FE model? Since the clustering should just impact my standard errors, if autocorrelation was present in my clustered FE model this would justify my clustering, no?

    2. I have the same question about heteroskedasticity: is there a way to test for it to justify clustering? Or is this unnecessary?

    Thanks very much.

  • #2
    You only need to test for heteroscedasticity and autocorrelation if you choose not to cluster. The reason is that in wide panels \((N>T)\), conventional standard errors are valid only under the assumption of homoscedasticity and no serial correlation. However, cluster-robust standard errors are valid both under the assumption of homoscedasticity and no serial correlation and under the assumption of heteroscedasticity and arbitrary forms of serial correlation. The only thing that you need to consider is whether you have enough levels in your cluster variable, which appears to be the case.

    Comment


    • #3
      Kate:
      as an aside to Andrew's helpful advice with such a long T dimension, it is virtually impossible that you do not have to cluster your standard errors.
      Your T dimension may also allow to consider whether AR(1) process are present in teh correlation of the systematic error (see -xtregar-).
      Kind regards,
      Carlo
      (Stata 19.0)

      Comment


      • #4
        Andrew and Carlo,

        Thank you both very much. You've helped answer an issue I've really been wrestling with.

        Andrew, as an aside, what do you mean by having enough levels in my cluster variable?

        Comment


        • #5
          Number of clusters, e.g., in #1, you will have the standard errors adjusted for 47 clusters in company. Note that the cluster-robust justification relies on \(N\rightarrow\infty\), so if \(N\) is too small (say less than 30), then it does not make sense to cluster.

          Comment


          • #6
            Kate:
            the following links can be helpful:

            https://www.nber.org/papers/w24003

            http://faculty.econ.ucdavis.edu/facu...5_February.pdf

            https://www.stata.com/meeting/wcsug07/cameronwcsug.pdf
            Kind regards,
            Carlo
            (Stata 19.0)

            Comment

            Working...
            X