Statistics
This chapter covers the following topics:
- Dispersion, mean, median, and mode
- Probability density function (PDF)
- Cumulative distribution function (CDF)
- Binomial distribution
- Normal distribution (Gaussian distribution)
- t-distribution
- Chi-square () distribution
- Gamma distribution
- Hypothesis testing
- Linear regression and goodness of fit
- Distribution functions and tables
Dispersion, mean, median, and mode
If represent the values of a random sample of items or observations, the arithmetic mean of these items or observations, denoted by , is defined as
The weighted arithmetic mean is
where
and
The variance of the population is the arithmetic mean of the squared deviations from the population mean. If is the arithmetic mean of a discrete population of size , the population variance is defined by
Standard deviation formulas (assuming statistical independence) are
The sample variance is
The sample standard deviation is
The sample coefficient of variation is
The sample geometric mean is
The sample root-mean-square value is
When the discrete data are rearranged in increasing order and is odd, the median is the value of the
item.
When is even, the median is the average of the
and
items.
The mode of a set of data is the value that occurs with the greatest frequency. The sample range is the largest sample value minus the smallest sample value.
Probability density function (PDF)
A probability density function (PDF) describes how probability is distributed across values of a continuous random variable. The PDF itself is not a probability; probabilities come from areas under the curve.
-
The PDF is denoted by .
-
The total area under the curve is 1:
- The probability that lies in the interval is the area under from to :
Example: PDF of the standard normal distribution:
Cumulative distribution function (CDF)
The cumulative distribution function (CDF) gives the probability that a random variable is less than or equal to a value . You can think of it as “accumulating” probability from the far left up to .
Properties:
Example: If for , then:
Binomial distribution
The binomial distribution models the number of successes in independent Bernoulli trials, where each trial has:
- two outcomes (success/failure)
- the same probability of success,
PMF (probability mass function):
- Mean:
- Variance:
Example: If and , then the probability of 3 successes is:
Normal distribution (Gaussian distribution)
The normal distribution is a symmetric, bell-shaped distribution used widely in statistics.
PDF:
- : mean
- : standard deviation
Standard normal distribution: ,
Example: Human height, IQ scores, etc.
t-distribution
The t-distribution is commonly used when the population standard deviation is unknown and the sample size is small.
PDF:
- : degrees of freedom
- Mean: 0
- Variance: for
Example: Used in the t-test for comparing sample means.
Chi-square () distribution
The chi-square distribution is often used in hypothesis testing involving variance and categorical data.
If are independent standard normal variables, then:
PDF:
- Mean:
- Variance:
Gamma distribution
The gamma distribution is a continuous distribution with two parameters: shape and rate (or scale ).
PDF:
- Mean:
- Variance:
Example: Time until the -th event in a Poisson process.
Hypothesis testing
Hypothesis testing is a statistical method for using sample data to make a decision about a population parameter.
Steps in hypothesis testing
-
State the hypotheses:
- Null Hypothesis: (no effect or no difference)
- Alternative Hypothesis: (an effect or difference exists)
-
Choose significance level:
- Denoted by (commonly 0.05)
-
Compute test statistic:
- For a population mean with known standard deviation:
-
Determine P-value:
- P-value: Probability of observing a value as extreme as the test statistic under .
-
Make a decision:
- If → Reject
- If → Fail to reject
Example
Scenario:
A bottling company claims the mean soda volume is 500 ml. A sample of 36 bottles has:
- Sample mean:
- Population standard deviation:
- Significance level:
Step 1: Hypotheses
- (Two-tailed test)
Step 2: Test statistic
Given:
- , , ,
Step 3: P-value
Using Z-tables:
Step 4: Decision
Since:
- → Reject
Conclusion: There is strong evidence that the mean volume is not 500 ml.
Confidence interval (CI)
To construct a 95% CI for the mean:
With:
- , , ,
Since 500 is not in the interval, we again reject .
Type I and Type II errors
| Error type | Description | Symbol | Consequence |
|---|---|---|---|
| Type I | Rejecting when it’s true | False positive | |
| Type II | Failing to reject when it’s false | False negative |
Power of the test:
- It is the probability of correctly rejecting a false .
Linear regression and goodness of fit
Linear regression models the relationship between a dependent variable and an independent variable using a line plus an error term:
Where:
- : dependent variable
- : independent variable
- : intercept of the regression line
- : slope of the regression line
- : error term
Least squares method
The least squares method chooses the line that minimizes the sum of squared differences between observed values and predicted values.
Formulas for best fit line:
Given data points , the slope and intercept are calculated as:
Where:
Example
Given data:
| 1 | 2 |
| 2 | 3 |
| 3 | 5 |
| 4 | 4 |
| 5 | 6 |
Step 1: Compute sums
Step 2: Compute slope and intercept
Final regression line:
Goodness of fit
Sample correlation coefficient
The correlation coefficient measures the strength and direction of the linear relationship:
Given :
Coefficient of determination
The coefficient of determination shows the proportion of variance in explained by the model:
Interpretation: 81% of the variation in is explained by the linear regression model.
Distribution functions and tables
Please refer to the FE Handbook for detailed distribution functions and tables.