Announcement

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

  • Calculate and store the confidence interval without ci command

    Hi. I am looking to calculate and store the confidence interval for each of the simulations I run. For example, I am running 2,000 simulations, and collecting and storing beta coefficients and standard errors for each of the 2000 simulations. If I use the ci command, it returns me with an average for all these simulations however, I wish to see the confidence interval for each of the 2000 simulations and store the result.

    I want to use a t test to calculate the upper limit and lower limit. I am not sure if this is possible, like storing the upper limit and lower limit the way I stored the beta and standard errors using local and replace commands.

  • #2
    Welcome back to Statalist, Rezwan.

    All the elements you need to compute the bounds of the confidence intervals are available after the regression: you can take a look at these by typing ereturn li

    You might also want to check out the statsby command prefix to conveniently store the results from each simulation.
    Last edited by Hemanshu Kumar; 02 Nov 2022, 01:25.

    Comment

    Working...
    X