From the wikipedia:

 

Standard deviation is a widely used measure of variability or diversity used in statistics and probability theory. It shows how much variation or "dispersion" there is from the average (mean, or expected value). A low standard deviation indicates that the data points tend to be very close to the mean, whereas high standard deviation indicates that the data points are spread out over a large range of values.

The standard deviation of a statistical population, data set, or probability distribution is the square root of its variance. It is algebraically simpler though practically less robust than the average absolute deviation.[1][2] A useful property of standard deviation is that, unlike variance, it is expressed in the same units as the data.

In addition to expressing the variability of a population, standard deviation is commonly used to measure confidence in statistical conclusions. For example, the margin of error in polling data is determined by calculating the expected standard deviation in the results if the same poll were to be conducted multiple times. The reported margin of error is typically about twice the standard deviation ­– the radius of a 95 percent confidence interval. In science, researchers commonly report the standard deviation of experimental data, and only effects that fall far outside the range of standard deviation are considered statistically significant – normal random error or variation in the measurements is in this way distinguished from causal variation. Standard deviation is also important in finance, where the standard deviation on the rate of return on an investment is a measure of the volatility of the investment.

When only a sample of data from a population is available, the population standard deviation can be estimated by a modified quantity called the sample standard deviation, explained below.


I've implemented a simple program in C language that takes data from a text file (one value on each raw). Here you are the source code:


 

 1 #include <stdio.h>
 2 #include <stdlib.h>
 3 #include <unistd.h>
 4 #include <math.h>
 5 
 6 #define MAX_ITEMS 16080
 7 
 8 int main (int argc, char** argv)
 9 {
10     FILE  *fp;
11     char  str[80];
12     int   number_of_items = 0;
13     float list[MAX_ITEMS], numerator = 0, denominator, xbar = 0;
14     float standard_deviation;
15     int   i;
16 
17     if(argc!=2)
18     {
19         printf("Usage %s <data_file.txt>\n", argv[0]);
20         exit(EXIT_FAILURE);
21     }
22     // Read data items from the text file data.txt
23     fp = fopen(argv[1], "r");
24     if(fp==NULL)
25     {
26         perror("fopen");
27         exit(EXIT_FAILURE);
28     }
29     while(!feof(fp))
30     {
31         if(number_of_items>=MAX_ITEMS)
32             break;
33         if(fgets(str, 80, fp)==NULL)
34             break;
35         else
36         {
37             list[number_of_items]=atof(str);
38             number_of_items++;
39         }
40     }
41     printf("number_of_items = %d\n", number_of_items);
42     fclose(fp);
43 
44     // find the mean (average) of the data
45     for (i = 0; i <= number_of_items; i++)
46         xbar = xbar + list[i];
47 
48     xbar = xbar / number_of_items;
49     printf("The mean (average) is %f\n", xbar);
50 
51     // find the standard deviation
52     denominator = number_of_items;
53 
54     for (i = 1; i <= number_of_items; i++)
55         numerator = numerator + pow((list[i] - xbar), 2);
56 
57     standard_deviation = sqrt (numerator/denominator);
58     printf("The standard deviation for the given data is %f\n", standard_deviation);
59 
60     return 0;
61 }
62 


Gg1