Announcement

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

  • İnteresting Problem About Xtbunitroot test (Karavias and Tzavalis (2014)

    ı have N:12 T:31 panel data. ı am researching agriculture subsideies how to effect inputs costs. I was decieded to perform structural break unit root test. when I do the same unitroot test more than once, the results are different each time. for example;


    İs this test Unreliable ? What do you recommend me about this stiuations?

    first result;

    Click image for larger version

Name:	y1 1.png
Views:	1
Size:	18.3 KB
ID:	1636540





    Second Results;
    Click image for larger version

Name:	y1 2 .png
Views:	1
Size:	18.6 KB
ID:	1636541


  • #2
    Eyup.
    it depends on the -bootstrap- procedure.
    If imposing th same -seed- value were an option, results should be the same.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3

      Fisrtly thank you profesor for answer my questions. can you briefly explain last sentece . Will this stiuations cause any problems in my thesis? Should I trust these results?

      Comment


      • #4
        Eyup:
        you can trust your results.
        As -boostrap- resamples with reintroduction, it is perfectly legal to obtain slight variations each time the -bootstrap- procedure runs.
        The usual fix to obtain the very same results, if feasible, is to impose the same -seed-.
        As you can see in the following toy-example, reversing -seed- causes most of the -bootstrap- results to differ (as expected):
        Code:
        . sysuse auto.dta
        (1978 Automobile Data)
        
        . quietly sum price
        
        . bootstrap r(mean), reps(1000) seed(12345) : quietly sum price
        (note: ignoring quietly)
        (running summarize on estimation sample)
        
        warning: Because summarize is not an estimation command or does not set e(sample), bootstrap has no way to determine which
                 observations are used in calculating the statistics and so assumes that all observations are used. This means that
                 no observations will be excluded from the resampling because of missing values or other reasons.
        
                 If the assumption is not true, press Break, save the data, and drop the observations that are to be excluded. Be
                 sure that the dataset in memory contains only the relevant data.
        
        <snip>
        
        Bootstrap results                               Number of obs     =         74
                                                        Replications      =      1,000
        
              command:  summarize price
                _bs_1:  r(mean)
        
        ------------------------------------------------------------------------------
                     |   Observed   Bootstrap                         Normal-based
                     |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
        -------------+----------------------------------------------------------------
               _bs_1 |   6165.257   337.5735    18.26   0.000     5503.625    6826.889
        ------------------------------------------------------------------------------
        
        . bootstrap r(mean), reps(1000) seed(12345) : quietly sum price
        (note: ignoring quietly)
        (running summarize on estimation sample)
        
        warning: Because summarize is not an estimation command or does not set e(sample), bootstrap has no way to determine which
                 observations are used in calculating the statistics and so assumes that all observations are used. This means that
                 no observations will be excluded from the resampling because of missing values or other reasons.
        
                 If the assumption is not true, press Break, save the data, and drop the observations that are to be excluded. Be
                 sure that the dataset in memory contains only the relevant data.
        
        <snip>
        
        Bootstrap results                               Number of obs     =         74
                                                        Replications      =      1,000
        
              command:  summarize price
                _bs_1:  r(mean)
        
        ------------------------------------------------------------------------------
                     |   Observed   Bootstrap                         Normal-based
                     |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
        -------------+----------------------------------------------------------------
               _bs_1 |   6165.257   337.5735    18.26   0.000     5503.625    6826.889
        ------------------------------------------------------------------------------
        
        . bootstrap r(mean), reps(1000) seed(53421) : quietly sum price
        (note: ignoring quietly)
        (running summarize on estimation sample)
        
        warning: Because summarize is not an estimation command or does not set e(sample), bootstrap has no way to determine which
                 observations are used in calculating the statistics and so assumes that all observations are used. This means that
                 no observations will be excluded from the resampling because of missing values or other reasons.
        
                 If the assumption is not true, press Break, save the data, and drop the observations that are to be excluded. Be
                 sure that the dataset in memory contains only the relevant data.
        
        <snip>
        
        Bootstrap results                               Number of obs     =         74
                                                        Replications      =      1,000
        
              command:  summarize price
                _bs_1:  r(mean)
        
        ------------------------------------------------------------------------------
                     |   Observed   Bootstrap                         Normal-based
                     |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
        -------------+----------------------------------------------------------------
               _bs_1 |   6165.257   342.7539    17.99   0.000     5493.471    6837.042
        ------------------------------------------------------------------------------
        
        .
        Two closing asides:
        1) as requested by the FAQ, please mention the non-official Stata commands and community-contributed commands/modules.Thanks. ;
        2) please, call me Carlo, like all on (and many more off) this forum do. Thanks.
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment


        • #5
          Carlo is right that without fixing the seed the bootstrap results will be different every time you run the command. However, I find the differences in the initial example quite substantial. I would not expect the bootstrap to be that volatile. Unfortunately, I do not see an option for controling the bootstrap with the xtbunitroot command. It might be worth contacting the authors of this community-contributed Stata command about this issue.
          https://www.kripfganz.de/stata/

          Comment


          • #6
            Addendum: The main problem here appears to be the very small number of panel units (12). Because the bootstrap resamples across units and not across time, a large number of panel units is needed for reliable inference. This explains the observed behavior.
            https://www.kripfganz.de/stata/

            Comment


            • #7
              thanks for valuable info

              Comment


              • #8
                I had the same problem. But I solved it by setting "seed".
                Not sure if this helps.

                Comment

                Working...
                X