|
Brighton Webs Ltd.
Statistics for Energy and the Environment
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
The Median The median divides a population into two halves. Half the values are less than the median and the other half are greater than the median. For example if the median time of the journey to work is 20 minutes, then you know that 50% of journeys will take less than 20 minutes and the rest will be longer. The median is less sensitive to extreme values than the mean (average) because it is based on the number of values, not their magnitude. When the set contains an odd number of values, the median is the central value, for example:
When the set contains an even number, then the mean of the two central values is used, for example:
The median, mean and the mode are often described as a measures of central tendancy. Related topics The Mean Calculation Unlike the mean (average), there is no formula for calculating the mean, it is derived from a two step procedure: Step 1 Step 2 Data for Example Calculation The sample calculation is based on a 38 year time series of the annual rainfall in a humid sub-tropical area. The frequency diagram for the data set is shown below: The left hand table shows th data in year order and the right hand table has been sorted such that the rainfall values are in ascending order which allows them to be ranked.
The minimum and maximum values are 625 and 1931 mm respectively and the mean (average) is 1279 mm Example calculation
The value of 2500 was arbitrarily chosen because it is anomalous, adding it to the dataset causes only a small increase in the median value from 1301 to 1314, however, the effect on the mean is larger it changes from 1279 to 1311. Spreadsheets Spreadsheets offer a relatively painless way of executing many statistical procedures, both Microsoft's Excel and Google Spreadsheet document have a median function,
The arguments can be either ranges or valid numbers, e.g.
Empty cells are ignored. Note for Programmers A lot of statistical literature is based on tables of data where the first entry is referenced as 1 e.g. x(1) and the last entry n e.g. x(n) where n is also the number of items in the table. In programming languages (e.g. c++, vb etc.) tables are often implemented as arrays where the first entry is referenced as 0 e.g. x(0) and the last item is x(n-1). Thus some care is required to implement statistical methods in code. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Page updated: 24-Apr-2012 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||