In Chemical industrial, samples are often analyzed multiple times, e.g. 5 samples and each was analyzed 2 times with 10 data points in total. What would be the confidence interval for the mean estimated from these data? The degrees of freedom is somewhere from 4 to 10 depending on the correlation between repeats.

  • $\begingroup$ The answer will depend on 1) the distribution you expect for the concentration of each sample (if you sample from a slightly heterogeneous solution), and on 2) the distribution of the errors of the analysis method. I assume there are usual hypothesis for this, like for 2) centered gaussian error, are you aware of this? $\endgroup$
    – Elvis
    Jan 5, 2012 at 20:43
  • $\begingroup$ Let's assume 2), i.e. the measurement error follows gaussian distribution. $\endgroup$ Jan 7, 2012 at 10:45

1 Answer 1


My question (in the comments) was mainly on the variation between samples. Is it normal? It is unclear to me, I suspect that for small concentrations it is not the good model. Anyway, let’s assume it is normal.

Let’s formalize a little bit. If $c$ is the true concentration, the concentration of sample $i$ is $C_i = c + E_i$ where $E_i \sim \mathcal N(0, \sigma_s^2)$ for $i=1,\dots,n$.

Each sample is analyzed $m$ times ($m=2$ in your case), and the measurement error is gaussian: this leads to measures $X_{ij} = c + E_i + F_{ij}$ where $F_{ij} \sim \mathcal N(0, \sigma_m^2)$ for $j=1,\dots,m$. All errors $E_i$ and $F_{ij}$ are independent.

Let’s call $Y_i$ the mean of the $m$ measures of sample $i$: $$Y_i = {1\over m} \sum_{j=1}^m X_{ij}.$$ The distribution of $Y_i$ is $\mathcal N\left(c, \sigma_1^2\right)$ where $\sigma_1^2 = \sigma^2_s + {1\over m} \sigma^2_m$.

Now we are in a perfectly classical situation. All $Y_i$ are independent, with the same normal distribution. The unknown concentration $c$ will be estimated by the sample mean $\hat c = {1\over n} \sum_{i=1}^n Y_i$. The variance $\sigma_1^2$ will be estimated as usual by $s_1^2 = {1\over n-1}\sum_i (Y_i - \hat c)^2$.

A confidence interval of level $1-\alpha$ is given by $$ \hat c \pm t^{n-1}_{1-\alpha/2} \sqrt{ {s_1^2 \over n} },$$ where $t^{n-1}_{1-\alpha/2}$ is the $1-\alpha/2$-th quantile of the distribition $t(n-1)$.

The answer to your question is that there are $n-1$ df, but the estimation of variance is not to be done as if all measures were independent. You have to follow this two steps procedure:

  1. compute the means of all $m$ measures of each sample;
  2. treat them as $n$ independent measures.

Edit: about the data of GJ Hahn (cf comments)

If you have two samples, each analysed 5 or more times, leading to average measures of 50 and 60, you can compute a 90% confidence interval with $$\begin{align*} & \hat c \pm t^{1}_{0.95} \sqrt{ {s_1^2 \over 2} }\\ =& 55 \pm 6.31 \sqrt{ {50\over 2}}\\ =& [23.4 \,;\, 86.6] \end{align*}$$

Alternatively, if you are only interested in a lower bound of the concentration (which is Hahn question, does the average exceed 40 ?), you can say that $[23.4,+\infty)$ is a 95% one-side confidence interval.

  • $\begingroup$ When applying your method to the following example with n=2 and m-5. Sample 1: avg=50 (50,51,49,51,49) and Sample 2: avg=60 (60,61,59,60,60). The 95% CI based on (50,60) is (-8,118) with df=1. The example is taken from "Beware of nonindependent observations" by Gerald Hahn (1977 Chemical Technology). The 95% CI from the artcile is (23,87). $\endgroup$ Jan 15, 2012 at 15:55
  • $\begingroup$ @AldousWong Are you suggesting that the method is wrong? What is the method used by Gerald Hahn? $\endgroup$
    – Elvis
    Jan 15, 2012 at 17:03
  • $\begingroup$ Note that this is 2 samples each analyzed 5 times, not 5 samples each analyzed 2 times... $\endgroup$
    – Elvis
    Jan 15, 2012 at 17:11
  • $\begingroup$ Hahn's article does not show calculation method. Based on the references, I think he is using Variance Component and some why adjusting the df. Working backward from (23,87) suggests the df > 1 but less than 2. Elvis, I am interested the right method to handle this type of data which are very common in process industries. $\endgroup$ Jan 18, 2012 at 4:34
  • $\begingroup$ @AldousWong Some additionnal hypotheses are needed that I can't figure out. Or there's a misprint in the paper... Can you put it in some place where we can download it? $\endgroup$
    – Elvis
    Jan 18, 2012 at 6:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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