0
$\begingroup$

I am kind of new in calculation of confidence interval, so I hope it will not be a too basic question.

I have a normal distribution (with slightly longer left tail) as you can see in the picture. The sample size is 2286 and I am trying to calculate the level of 99% CI (confidence interval) with the formula below:

enter image description here

x_bar is the mean value of the sampled data which is around 7.57,

t_star is the confidence coefficient from the t-table which is 2.576 because of the size of the sample data,

s is estimated standard deviation which is around 1.71 (the standard deviation value is generated in SAS-program with std function),

and n is the sample size which is 2286 as mentioned above.

So the formula gives the upper limit as 7.66 with 99% confidence intervall. However, according to the histogram like below, I should get a value around 11.

What am I doing wrong?

enter image description here

$\endgroup$
2
$\begingroup$

The formula looks about right, so I say you have gotten the CI right as well.

I think the problem is that you may be mixing the concept of the confidence interval (which is associated with the mean and how accurately we can estimate it) with the empirical distribution percentiles.

The confidence interval says that with p% probability is the true but unknown distribution mean between these two boundaries (in your case 99%)

The 1% and 99% percentile give information on the boundaries of the entire distribution, saying that 98% of the distribution is located between the 1st and 99th percentile, given the assumed distribution mean and SD.

if ds is your data vector, the following function call will give you the distribution percentiles, which you will find in line with your histogram. I simulated some data below just for display

 ds<-rnorm(2286,7.57,1.71)
quantile(ds,c(.01,.99))
       1%       99% 
 3.576438 11.527171 

Trying either your formula, or using the t.test function in R will give you the confidence interval.

t.test(ds,conf.level=.99)

    One Sample t-test

data:  ds
t = 211.21, df = 2285, p-value < 2.2e-16
alternative hypothesis: true mean is not equal to 0
99 percent confidence interval:
 7.503461 7.688899
sample estimates:
mean of x 
  7.59618

Hope this was helpful.

$\endgroup$
  • $\begingroup$ thanks. So Confidence Interval gives an interval around the expected value (mean value) of the dataset. The purpose of this statistic was putting a limit for risk. The samples are coming from same data type. I wanted to put an upper limit and say "OK, my data can have a maximum value with 90% or 99% probability. Over this 90% or 99% level, it will be risky data for me". $\endgroup$ – user3714330 May 24 '16 at 8:57
  • $\begingroup$ Good approach, using the percentile instead. $\endgroup$ – Arga Statistikern May 24 '16 at 11:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.