A teacher holding the marks of 20 students in a list finds it hard to see how many scored below 20 or between 30 and 40. Arranging the marks into groups gives the answer at a glance. This arrangement is called classification.
Classification
Classification is the process of arranging data into groups or classes according to common features. Data can be classified by time (chronological), by place (geographical), by quality (qualitative) or by numerical size (quantitative). Unorganised figures as collected are called raw data. Arranging raw data in ascending or descending order gives an array.
Definition: Frequency distribution. A table that shows the values of a variable, or classes of values, together with the number of times each occurs.
Discrete and Continuous Frequency Distributions
In a discrete frequency distribution each distinct value is listed with its frequency. In a continuous frequency distribution the values are grouped into class intervals, and the number of observations in each class is its class frequency. The smallest and largest values of a class are the class limits, the difference of the limits is the class width, and the average of the two limits is the class mark or mid-point. In the exclusive method the upper limit of a class is not included in it, so a value of 20 belongs to the class 20 to 30.
Constructing a Frequency Distribution
The steps are The range of the data is found, the number of classes is chosen, the class width is calculated and tally marks are made to count the frequencies. Sturges' rule suggests the number of classes k = 1 + 3.322 log n, where n is the number of observations and the logarithm is to base 10. A cumulative frequency is the running total of the class frequencies.
Table 1.2: Frequency distribution of the marks of 20 students
| Class | Class mark | Frequency | Cumulative frequency | Percentage |
|---|---|---|---|---|
| 10 to 20 | 15 | 3 | 3 | 15 |
| 20 to 30 | 25 | 8 | 11 | 40 |
| 30 to 40 | 35 | 6 | 17 | 30 |
| 40 to 50 | 45 | 3 | 20 | 15 |
Example 1.2: Preparing a frequency distribution
Problem: The marks of 20 students out of 50 are 12, 15, 18, 20, 22, 22, 25, 25, 25, 27, 28, 30, 30, 32, 34, 35, 38, 40, 42 and 45. Group them in classes of width 10 starting at 10.
Solution:
- The range is 45 - 12 = 33, so four classes of width 10 are enough.
- Count the values in each class with the upper limit excluded: 10 to 20 has 12, 15, 18, which is 3 values.
- The class 20 to 30 has 20, 22, 22, 25, 25, 25, 27, 28, which is 8 values.
- The class 30 to 40 has 30, 30, 32, 34, 35, 38, which is 6 values, and 40 to 50 has 40, 42, 45, which is 3 values.
Result: The frequencies are 3, 8, 6 and 3, with a total of 20.
x = [12, 15, 18, 20, 22, 22, 25, 25, 25, 27, 28, 30, 30, 32, 34, 35,
38, 40, 42, 45]
for lo in (10, 20, 30, 40):
print(lo, "to", lo + 10, sum(lo <= v < lo + 10 for v in x))
Output
10 to 20 3
20 to 30 8
30 to 40 6
40 to 50 3
Common mistakes
- Overlapping the classes in the exclusive method, so that a value belongs to two classes.
- Using classes of unequal width without a reason.
- Making the table with too few or too many classes, which hides the pattern of the data.
Key takeaways
- Classification arranges data into groups with common features.
- A class has limits, a width and a class mark.
- A cumulative frequency is a running total of frequencies.
- Sturges' rule gives a guide for the number of classes.
Practice questions
- What is a class interval?
- How is the class mark found?
- What is a cumulative frequency?
Answers to the practice questions
- A group of values, defined by a lower and an upper limit, into which observations are placed.
- As the average of the lower and upper class limits.
- The running total of the class frequencies up to a class.
Sources
- Official BCA syllabus Probability and Statistics, course code 26BCA403DS01, Unit I
