Announcement

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

  • Error xlag(): 3301 subscript invalid while running xtcointreg.

    Hello this is my first post. I really hope I will get some help from here. I am running the command xtcointreg on stata 16 on a panel data of 56 observations. I am trying to find fmols and dols. but every single time i run the command the following error message pops up:

    xlag(): 3301 subscript invalid
    autobwidth(): - function returned error
    lrcovkernel(): - function returned error
    _lrcov(): - function returned error
    cointreg(): - function returned error
    <istmt>: - function returned error


    Please help me out. I have my undergrad thesis due n a week but am stuck at this place.

  • #2
    I see that xtcointreg is from SSC. As your dataset is just 56 observations, you should be able to post it here using dataex, together with the exact code you used.

    As it stands, it seems hard to tell whether the data, what you're asking, or the program itself is the problem.

    Please read https://www.statalist.org/forums/help#stata if you have not done so already, or follow its advice any way.

    Comment


    • #3
      Dear Nick Cox ,
      I am also having the same issues when running the xtcointreg command.

      xlag(): 3301 subscript invalid
      autobwidth(): - function returned error
      lrcovkernel(): - function returned error
      _lrcov(): - function returned error
      cointreg(): - function returned error
      <istmt>: - function returned error

      Is there any way to solve this problem?

      Regards

      Comment


      • #4
        Hello,

        I am having the same issue when running the xtcointreg command in Stata 18.5. I have 87 cross-sections with a time period of 13 years, in this example format:

        country income time ln_gdp ln_gdppc ln_rec ln_capital ln_labor ln_tech_exports ln_life ln_corruption ln_law ln_trade
        Albania upper_mid 2009 23.03061 8.140948 3.613617 21.89039 14.03642 .2838198 4.353897 3.553295 3.635339 4.318753
        Albania upper_mid 2010 23.06701 8.182312 3.610918 21.80189 14.04596 .3815256 4.355888 3.614771 3.753122 4.337858
        Albania upper_mid 2011 23.09215 8.210137 3.577948 21.85963 14.13536 .0167322 4.357888 3.204556 3.721215 4.397144
        Albania upper_mid 2012 23.10622 8.225862 3.686376 21.77779 14.09135 -.0805194 4.357529 3.223604 3.686529 4.337424
        Albania upper_mid 2013 23.11619 8.237664 3.716008 21.75783 14.01203 -.1162664 4.358284 3.185138 3.662719 4.32907
        Albania upper_mid 2014 23.13378 8.257323 3.653252 21.71129 14.03397 -1.357766 4.361913 3.530312 3.789421 4.322911
        Albania upper_mid 2015 23.15573 8.282181 3.650658 21.74569 14.07406 .4911475 4.364931 3.588796 3.790662 4.273899
        Albania upper_mid 2016 23.18834 8.316391 3.673766 21.76968 14.10945 -.2429466 4.367674 3.627511 3.735399 4.31495
        Albania upper_mid 2017 23.22566 8.354632 3.608212 21.82827 14.12537 -2.425228 4.370043 3.700714 3.652512 4.359196
        Albania upper_mid 2018 23.26506 8.396506 3.632309 21.85146 14.14742 -3.107737 4.371774 3.506558 3.614771 4.3267
        Albania upper_mid 2019 23.28548 8.421182 3.691376 21.82914 14.16322 -2.052392 4.373011 3.462755 3.640089 4.322571
        Albania upper_mid 2020 23.25178 8.393226 3.793239 21.82029 14.11739 -1.252272 4.343663 3.462755 3.688879 4.086324
        Albania upper_mid 2021 23.33768 8.488393 3.735286 21.99892 14.12867 -.868668 4.336807 3.462755 3.757872 4.325328

        I have no missing values.

        The code I am running is:

        ssc install xtcointreg
        xtcointreg ln_gdppc ln_rec ln_capital ln_labor ln_tech_exports ln_life ln_law ln_trade, est(dols)

        Then, I receive the error:

        xlag(): 3301 subscript invalid
        autobwidth(): - function returned error
        lrcovkernel(): - function returned error
        _lrcov(): - function returned error
        cointreg(): - function returned error
        <istmt>: - function returned error


        r(3301);

        All the other panel tests I have run (cross-sectional dependence, unit-root, cointegration) have worked perfectly. Also, normal panel regression on this data (xtreg) works perfectly.

        Any insight would be amazing, thank you!

        Comment

        Working...
        X