I have some random numbers which are generated from Gaussian Distribution. But I don't know the mean, standard deviation of that distribution. How can I find them using random numbers?

  • 3
    $\begingroup$ If the only thing you have available to you is the sample of random numbers, this is impossible. But you can estimate them by computing the empirical mean and standard deviation. $\endgroup$
    – ocram
    Commented Jan 8, 2012 at 9:08
  • $\begingroup$ @ocram Yeah, I have only large amount of random numbers generated from Gaussian Distribution. $\endgroup$
    – user
    Commented Jan 8, 2012 at 9:21
  • $\begingroup$ Then, both the mean and variance can be estimated from your sample. @David Robinson has clarified that point. $\endgroup$
    – ocram
    Commented Jan 8, 2012 at 9:42

1 Answer 1


You can estimate them. The best estimate of the mean of the Gaussian distribution is the mean of your sample- that is, the sum of your sample divided by the number of elements in it.

$$\bar{x} = \frac{1}{n}\sum_{i=1}^nx_i$$

The most common estimate of the standard deviation of a Gaussian distribution is

$$\bar{s} = \sqrt{\frac{1}{n-1}\sum_{i=1}^n\left(x_i - \bar{x}\right)^2}.$$

Here, $x_i$ is the $i^\text{th}$ number in your sample. See Wikipedia for details.

  • $\begingroup$ Thanks, edited to add this. But of course you meant to add 1/n. $\endgroup$ Commented Jan 8, 2012 at 21:46

Your Answer

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

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