Example Data Set
To show how to calculate mean, median, mode, and range, I will use the following data set:
How Do You Calculate the Mean?
The mean is the average of all numbers in a data set. To calculate the mean of a set of numbers, you add all of the numbers together and then divide that sum by the number of elements within the set.
How Do You Calculate the Median?
The median is the middle number in a data set after sorting the data set from smallest to largest. To calculate the median of a data set, you count the number of elements and then sort the elements from smallest to largest. Next, for an odd number of elements, you add 1 to the number of elements and then divide by 2 to get the position of the middle number. From our example data set, the median is the 7th number in the sorted list, which is the number 17.
Note that for an even number of elements, you find the average of the two middle numbers. The first middle position would be equal to the number of elements divided by 2 less 1. The second middle position would be the first middle position plus 1. You then add the two middle numbers together and divide by 2 to find the average. From our revised example data set, this gives you a medium of 16 -- which is the average of the 6th and 7th elements (15 and 17).
How Do You Calculate the Mode?
The mode is the number in a data set that is repeated the most often within the set. To find the mode, you simply count the number of times each unique number appears within the data set. The number that appears most often is the mode. In our example data set, the number that appears the most often is 8. Therefore the mode of the data set is 8.
Note that a data set can have more than 1 mode. For example, if the above data set included another 3, then the set would have two modes: 3 and 8. A data set having two modes is referred to as a bimodal set, whereas a data set having more than two modes is referred to as a multimodal set.
How Do You Calculate the Range?
The range is the difference between the largest number within the set and the smallest number in the set. To find the range, you sort the range from smallest to largest to determine the minimum and maximum values. You then subtract the minimum value from the maximum value to find the range. In our example set the minimum is 3, and the maximum is 36, which would result in a range of 33 (36 - 3).