Announcement

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

  • #16
    I am attaching a table from a research paper where the authors used bootstrap approach rather than assuming normality for determining the significance level. This is what I am trying to do in Stata and I am not sure how to program it. Thank you

    Comment


    • #17
      Wouldn't it be more informative to show the Methods section?

      Comment


      • #18
        There are not details at all.

        Comment


        • #19
          This paper uses the approach.
          http://download.springer.com/static/...6a159&ext=.pdf
          This has more details on bootstrap t confidence interval , page 7 Bootstrapping.pdf
          Is this doable with Stata commands?
          Attached Files
          Last edited by Lilly; 05 May 2014, 04:58.

          Comment


          • #20
            Lilly, my point was that for you to be able to get to e2 you would have to preserve the dataset before the keep command, do your operations and then restore. In the code you submitted it would look something like
            Code:
            program define Boot, rclass
            forvalues j = 1/224 {
                preserve
                keep Number e`j'
                drop if mi(e`j')
                bsample
                centile e`j', centile(.5 2.5 5 95 97.5 99.5)
                return scalar CV1`j'=r(c_1)
                return scalar CV2`j'=r(c_2)
                return scalar CV3`j'=r(c_3)
                return scalar CV4`j'=r(c_4)
                return scalar CV5`j'=r(c_5)
                return scalar CV6`j'=r(c_6)
                restore
            }
            end
            Alfonso Sanchez-Penalver

            Comment


            • #21
              Thank you Alfonso; it is most likely that the above code is not doing what I want. I want to be able to bootstrap t confidence interval.

              Comment


              • #22
                What is the estimation command for this model? Because looking at the picture I think that all you have to do is bootstrap the vce of that estimation.
                Alfonso Sanchez-Penalver

                Comment


                • #23
                  I am using xtpcse and xtgls.

                  Comment


                  • #24
                    These are the two approaches; the percentile method (attachment 2) and the bootstrap t-confidence interval method (attachment 1) from "Bootstrapping, Christiana Hilmer, DOI:http://dx.doi.org/10.4135/9781412961288.n34 , pages 7 and 8". Are there set of commands on Stata for either approaches?
                    Last edited by Lilly; 05 May 2014, 17:57.

                    Comment


                    • #25
                      I got this code which bootstraps the t-statistic for cross-sectional data:

                      bootstrap _b _se, reps(1000) ndots saving(bsdata, replace): regress Y X, hc2
                      regress Y X, hc2
                      use bsdata
                      generate t_X = (b_X - _b[X]) / se_X
                      centile t_X, centiles(2.5 97.5)

                      Along the same lines, I would like to adapt this code to panel data with correlated, heteroskedastic, and non-normally distributed residuals. I am using xtpcse and xtgls commands.

                      Many thanks.
                      Last edited by Lilly; 06 May 2014, 02:39.

                      Comment

                      Working...
                      X