Descriptive Statistics
Lesson Introduction
Welcome to our lesson on Descriptive Statistics! In this lesson, we will learn how to summarize and describe important features of a data set. By the end, you'll know how to calculate measures like the mean and standard deviation, which are crucial for understanding data in machine learning and many other fields.
Descriptive statistics help us get a quick overview of large amounts of data. Imagine understanding the average test scores of students or the variability in their heights. Descriptive statistics provide the tools for this efficiently.
Mean
The mean is the average of a set of numbers. Imagine test scores: 80, 85, 90, 75, and 95. To find the mean:
- Add the scores:
- Divide by the number of scores:
The mean score is 85. It gives us the "central" value.
Standard Deviation
The standard deviation measures how spread out numbers are. For our test scores example:
- Find the mean score: 85.
- Subtract the mean from each score and square the result:
- Find the average of these squared differences:
- Take the square root:
A standard deviation of about 7.07 tells us the scores vary on average by 7.07 points from the mean. Low standard deviation means data points are close to the mean, while high indicates they are spread out.
Median
The median is another measure of central tendency that represents the middle value of a data set when it is arranged in order. It is particularly useful when the data set contains outliers, as the median is not affected by extreme values.
For example, consider the test scores: 75, 80, 85, 90, and 95. To find the median:
- Arrange the scores in order: 75, 80, 85, 90, 95
- Find the middle score: 85
If the data set contains an even number of values, the median is the average of the two middle numbers.
For instance, with scores: 75, 80, 85, and 95:
- Arrange in order: 75, 80, 85, 95
- Find the middle scores: 80 and 85
- Calculate their average:
The median is useful in situations where the mean might be misleading due to outliers or skewed data distributions.
