Announcement

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

  • precision estimates

    I am wondering is there a command to get precision estimates for a sample size. I’ve been doing these by hand based on available SDs reported in the literature by country, but I was hoping this could essentially be automated in Excel/Stata/R.

    Currently, I’m aiming for a 95% CI for mean total direct cost. Which gives me a raw margin of error +/- over different sample sizes. I’ve found lots of previous published work which takes the view from the opposite side and calculates the required sample size, rather than the change in MOE over differing sample sizes.

    Most of the literature will refer to power and sample size, which isn’t relevant in my case for now as I’m not aiming to compare means within the sample. Our aim is to have a sample size what will reflect a precise (or as precise as we can make it) measurement of the variable of interest

  • #2
    You didn't get a quick answer. You'll increase your chances of a useful answer by providing Stata code in code delimiters, readable Stata output, and sample data using dataex.

    I'm not sure exactly what you are asking. Any calculation of means will give you a "95% CI" for the mean.

    The short answer is larger sample sizes almost always give more precise measures.

    You seem to want a specific level of precision. Stata's power command will help you. It may not calculate the numbers the direction you want, but you can always create the table and work backwards.

    Comment


    • #3
      while there is literature on this way of calculating sample size, I don't know of any command in Stata to do this; when I have wanted this, I built a loop that would take a sample size, create the CI and move to the next sample size; for my purposes, I created the width of each CI and those widths are what I examined in conjunction with the substantive experts I was working with to get a narrow enough CI for their purposes; there are many commands (e.g., -ci-, -means-) that calculate ci's for means and keep the result so you can grab what you want

      Comment

      Working...
      X