The Wald Sequential Probability Ratio Test (SPRT) is a statistical test proposed by Abraham Wald in 1945. It is a sequential hypothesis test, meaning that it can be applied repeatedly as observations are collected, allowing for early termination of the test once sufficient evidence is obtained.
In contrast to traditional hypothesis tests such as the t-test or the chi-squared test, which require a fixed sample size determined in advance, the SPRT is designed to minimize the expected sample size, which makes it particularly useful for quality control and industrial applications.
The test operates by comparing the likelihood ratio of the observed data to two predefined boundaries, one for accepting the null hypothesis (H0) and another for accepting the alternative hypothesis (H1). The likelihood ratio is the probability of obtaining the observed results under the alternative hypothesis divided by the probability of obtaining the observed results under the null hypothesis.
Here is an overview of how the SPRT works:
- Define the null hypothesis (H0) and the alternative hypothesis (H1).
- Choose Type I error (α) and Type II error (β) levels. These correspond to the probabilities of incorrectly rejecting H0 and failing to reject H0 when H1 is true, respectively.
- Calculate the boundaries A and B, such that A < B. These boundaries are determined based on the desired α and β, as well as the likelihoods under H0 and H1. If the likelihood ratio falls below A, we accept H0; if it exceeds B, we accept H1.
- Collect data sequentially and compute the likelihood ratio after each new observation.
- Compare the likelihood ratio to the boundaries after each observation:
- If the ratio is less than A, stop and accept H0.
- If the ratio is greater than B, stop and accept H1.
- If the ratio is between A and B, continue collecting data.
Here’s the formula for the logarithm of the likelihood ratio for a single observation, which is typically used for easier computation:
Log likelihood ratio = log(L(H1) / L(H0)) = n * log(θ1/θ0) - (n - x) * log((1-θ1)/(1-θ0)),
where:
- n is the number of observations,
- x is the number of successes among the observations,
- θ0 is the probability of success under H0,
- θ1 is the probability of success under H1.
Advantages of the SPRT include the potential for significantly shorter testing and faster decision-making as well as efficiency in terms of sample size. However, it's important to note that applying the SPRT correctly requires careful planning and an understanding of the process being studied and statistical principles. Additionally, it may not be suitable for all contexts, especially when sample collection is costly or when observations are not independent.