
Re: Simulation for the standard deviation
Posted:
Feb 23, 2013 7:58 AM


On 22/02/2013 21:06, Ray Koopman wrote: > On Feb 22, 6:05 am, Cristiano <cristi...@NSgmail.com> wrote: >> On 22/02/2013 6:15, Ray Koopman wrote: >>> On Feb 20, 3:54 am, Cristiano <cristi...@NSgmail.com> wrote: >>> >>>> Short question: does anybody know how to calculate the confidence >>>> interval of the standard deviation for the uniform distribution? >>> >>> For n iid samples from a continuous uniform distribution, >>> Pr(r/R <= x) = F(x) = n*x^(n1)  (n1)*x^n, where >>> r is the sample range, R is the true range, and 0 <= x <= 1. >>> A 100p% confidence interval for R is R >= r/x, where F(x) = p. >>> Divide that by sqrt(12) to get a lower bound for the SD. >> >> Suppose I randomly pick 0.1, 0.4 and 0.2 (n = 3); >> what should I write to calculate a 99% confidence interval? > > F(x) = 3 x^2  2 x^3 = p > > F(.941097) = .99 > > SD >= (.4  .1)/(.941097 * sqrt(12))
That lower bound doesn't work. According to the practical definition of CI given here: http://www.itl.nist.gov/div898/handbook/eda/section3/eda352.htm I wrote a simulation which counts how many times the sample SD exceeds the calculated lower bound. Using 10^6 trials and a confidence level of .9, I see that the calculated SD is greater than your lower bound 10^6 times, while the calculated SD is greater than my lower bound 900221 times (I find the confidence limits as explained in my original post).
Cristiano

