A large standard deviation indicates that the data points can spread far from the mean and a small standard deviation indicates that they are clustered closely around the mean. For example, each of the three populations {0, 0, 14, 14}, {0, 6, 8, 14} and {6, 6, 8, 8} has a mean of 7. Their standard deviations are 7, 5, and 1, respectively. The third population has a much smaller standard deviation than the other two because its values are all close to 7. These standard deviations have the same units as the data points themselves. If, for instance, the data set {0, 6, 8, 14} represents the ages of a population of four siblings in years, the standard deviation is 5 years. As another example, the population {1000, 1006, 1008, 1014} may represent the distances traveled by four athletes, measured in meters. It has a mean of 1007 meters, and a standard deviation of 5 meters. Standard deviation may serve as a measure of uncertainty. In physical science, for example, the reported standard deviation of a group of repeated
measurements gives the
precision of those measurements. When deciding whether measurements agree with a theoretical prediction, the standard deviation of those measurements is of crucial importance: if the mean of the measurements is too far away from the prediction (with the distance measured in standard deviations), then the theory being tested probably needs to be revised. This makes sense since they fall outside the range of values that could reasonably be expected to occur if the prediction were correct and the standard deviation appropriately quantified. See
prediction interval. While the standard deviation does measure how far typical values tend to be from the mean, other measures are available. An example is the
mean absolute deviation, which might be considered a more direct measure of average distance, compared to the
root mean square distance inherent in the standard deviation.
Application examples The practical value of understanding the standard deviation of a set of values is in appreciating how much variation there is from the average (mean).
Experiment, industrial and hypothesis testing Standard deviation is often used to compare real-world data against a model to test the model. For example, in industrial applications the weight of products coming off a production line may need to comply with a legally required value. By weighing some fraction of the products an average weight can be found, which will always be slightly different from the long-term average. By using standard deviations, a minimum and maximum value can be calculated that the averaged weight will be within some very high percentage of the time (99.9% or more). If it falls outside the range then the production process may or not need to be corrected. Statistical tests such as these are particularly important when the testing is relatively expensive. For example, if the product needs to be opened and drained and weighed, or if the product was otherwise used up by the test. In experimental science, a theoretical model of reality is used.
Particle physics conventionally uses a standard of "
5 sigma" for the declaration of a discovery. A five-sigma level translates to one chance in 3.5 million that a random fluctuation would yield the result. For example, this level of certainty was required by each of two independent particle physics experiments at
CERN in order to announce that the
Higgs boson had been discovered, or by the
LIGO Scientific Collaboration to
conclusively confirm the existence of
gravitational waves.
Weather As a simple example, consider the average daily maximum temperatures for two cities, one inland and one on the coast. It is helpful to understand that the range of daily maximum temperatures for cities near the coast is smaller than for cities inland. Thus, while these two cities may each have the same average maximum temperature, the standard deviation of the daily maximum temperature for the coastal city will be less than that of the inland city as, on any particular day, the actual maximum temperature is more likely to be farther from the average maximum temperature for the inland city than for the coastal one.
Finance In finance, standard deviation is often used as a measure of the
risk associated with price-fluctuations of a given asset (stocks, bonds, property, etc.), or the risk of a portfolio of assets (actively managed mutual funds, index mutual funds, or ETFs). Risk is an important factor in determining how to efficiently manage a portfolio of investments because it determines the variation in returns on the asset or portfolio and gives investors a mathematical basis for investment decisions (known as
mean-variance optimization). The fundamental concept of risk is that as it increases, the expected return on an investment should increase as well, an increase known as the risk premium. In other words, investors should expect a higher return on an investment when that investment carries a higher level of risk or uncertainty. When evaluating investments, investors should estimate both the expected return and the uncertainty of future returns. Standard deviation provides a quantified estimate of the uncertainty of future returns. For example, assume an investor had to choose between two stocks. Stock A over the past 20 years had an average return of 10 percent, with a standard deviation of 20
percentage points (pp) and Stock B, over the same period, had average returns of 12 percent but a higher standard deviation of 30 pp. On the basis of risk and return, an investor may decide that Stock A is the safer choice, because Stock B's additional two percentage points of return is not worth the additional 10 pp standard deviation (greater risk or uncertainty of the expected return). Stock B is likely to fall short of the initial investment (but also to exceed the initial investment) more often than Stock A under the same circumstances, and is estimated to return only two percent more on average. In this example, Stock A is expected to earn about 10 percent, plus or minus 20 pp (a range of 30 percent to −10 percent), about two-thirds of the future year returns. When considering more extreme possible returns or outcomes in future, an investor should expect results of as much as 10 percent plus or minus 60 pp, or a range from 70 percent to −50 percent, which includes outcomes for three standard deviations from the average return (about 99.7 percent of probable returns). Calculating the average (or arithmetic mean) of the return of a security over a given period will generate the expected return of the asset. For each period, subtracting the expected return from the actual return results in the difference from the mean. Squaring the difference in each period and taking the average gives the overall variance of the return of the asset. The larger the variance, the greater risk the security carries. Finding the square root of this variance will give the standard deviation of the investment tool in question. Financial time series are known to be non-stationary series, whereas the statistical calculations above, such as standard deviation, apply only to stationary series. To apply the above statistical tools to non-stationary series, the series first must be transformed to a stationary series, enabling use of statistical tools that now have a valid basis from which to work.
Geometric interpretation To gain some geometric insights and clarification, we will start with a population of three values, . This defines a point in . Consider the line . This is the "main diagonal" going through the origin. If our three given values were all equal, then the standard deviation would be zero and would lie on . So it is not unreasonable to assume that the standard deviation is related to the
distance of to . That is indeed the case. To move orthogonally from to the point , one begins at the point: M = \left(\bar{x}, \bar{x}, \bar{x}\right) whose coordinates are the mean of the values we started out with. {{Collapse top|title=Derivation of M = \left(\bar{x}, \bar{x}, \bar{x}\right)}} M is on L therefore M = (\ell,\ell,\ell) for some \ell \in \mathbb{R}. The line is to be orthogonal to the vector from to . Therefore: \begin{align} L \cdot (P - M) &= 0 \\[4pt] (r, r, r) \cdot (x_1 - \ell, x_2 - \ell, x_3 - \ell) &= 0 \\[4pt] r(x_1 - \ell + x_2 - \ell + x_3 - \ell) &= 0 \\[4pt] r\left(\sum_i x_i - 3\ell\right) &= 0 \\[4pt] \sum_i x_i - 3\ell &= 0 \\[4pt] \frac{1}{3}\sum_i x_i &= \ell \\[4pt] \bar{x} &= \ell \end{align} A little algebra shows that the distance between and (which is the same as the
orthogonal distance between and the line ) \sqrt{\sum_i \left(x_i - \bar{x}\right)^2} is equal to the standard deviation of the vector , multiplied by the square root of the number of dimensions of the vector (3 in this case).
Chebyshev's inequality An observation is rarely more than a few standard deviations away from the mean. Chebyshev's inequality ensures that, for all distributions for which the standard deviation is defined, the amount of data within a number of standard deviations of the mean is at least as much as given in the following table.
Rules for normally distributed data s. The
central limit theorem states that the distribution of an average of many independent, identically distributed random variables tends toward the famous bell-shaped normal distribution with a
probability density function of f\left(x, \mu, \sigma^2\right) = \frac{1}{\sigma\sqrt{2\pi}} e^{-\frac{1}{2}\left(\frac{x - \mu}{\sigma}\right)^2}, where is the
expected value of the random variables, equals their distribution's standard deviation divided by , and is the number of random variables. The standard deviation therefore is simply a scaling variable that adjusts how broad the curve will be, though it also appears in the
normalizing constant. If a data distribution is approximately normal, then the proportion of data values within standard deviations of the mean is defined by: \text{Proportion} = \operatorname{erf}\left(\frac{z}{\sqrt{2}}\right) where \textstyle\operatorname{erf} is the
error function. The proportion that is less than or equal to a number, , is given by the
cumulative distribution function: \text{Proportion} \le x = \frac{1}{2}\left[1 + \operatorname{erf}\left(\frac{x - \mu}{\sigma\sqrt{2}}\right)\right] = \frac{1}{2}\left[1 + \operatorname{erf}\left(\frac{z}{\sqrt{2}}\right)\right]. If a data distribution is approximately normal then about 68 percent of the data values are within one standard deviation of the mean (mathematically, , where is the arithmetic mean), about 95 percent are within two standard deviations (), and about 99.7 percent lie within three standard deviations (). This is known as the
68–95–99.7 rule, or
the empirical rule. For various values of , the percentage of values expected to lie in and outside the symmetric interval, , are as follows: == Standard deviation matrix ==