Announcement

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

  • Panel Cointegration for data with gaps in the time series

    Hello,
    I have panel data N=19 and T=29 with gaps in the time series. I need to do cointegration. The known Stata tests; xtcointtest and xtwest require data without gaps in the series. I have searched and didn't seem to find a code to handle my data. I am using Stata 15. Any help to find a code to handle my data?
    Justice.

  • #2
    For economic time series, you can fill in missing values by interpolation or extrapolation. Some interpolation methods may be better relative to linear interpolation, depending on the variable. See

    Code:
    help ipolate
    and

    Code:
    ssc install mipolate
    help mipolate

    which has more methods available. Then you just have to state that, e.g., "missing values were filled using linear interpolation and extrapolation".
    Last edited by Andrew Musau; 21 May 2022, 12:13.

    Comment


    • #3
      Thank so mcuh, Andrew Musau.
      I will try it and revert.
      Regards.

      Comment


      • #4
        I got aroud making the panel balanced by filling in the missing values by inter and extrapolation. Thanks.
        However, is it the case that no Stata code exists to run cointegration for panel data with gaps (holes) in the time series?

        Comment


        • #5
          Have you tried

          Code:
          tsfill, full
          before running the command?

          Comment


          • #6
            Sorry for the late response.
            No. I did not try it. The gaps were across all the variables. So, I had to compute the interpolation and extrapolations manually.

            Comment


            • #7
              I still need a response to this part of my question: "However, is it the case that no Stata code exists to run cointegration for panel data with gaps (holes) in the time series?"

              Comment


              • #8
                Originally posted by Justice Djokoto View Post
                I still need a response to this part of my question: "However, is it the case that no Stata code exists to run cointegration for panel data with gaps (holes) in the time series?"
                If the gaps are either at the start or end of the series, see https://journals.sagepub.com/doi/pdf...867X1401400312. But the command is for large \(N\) and large \(T\).
                Last edited by Andrew Musau; 24 May 2022, 15:31.

                Comment


                • #9
                  Thank you, Andrew.

                  Comment

                  Working...
                  X