One-Sample Wilcoxon Signed-Rank Test

Sample Data (n=0)

Hypothesized Median (\(\eta_0\))

Your results will be displayed here.

Understanding the One-Sample Wilcoxon Signed-Rank Test

The One-Sample Wilcoxon Signed-Rank Test is a non-parametric test that determines whether the median of a sample is equal to a specific, hypothesized value. It is the non-parametric equivalent of the one-sample t-test and is used when the data cannot be assumed to be normally distributed.

When to Use this Test

This test is appropriate when you have a single set of data and want to compare its median to a known standard, target, or theoretical value. For example, you could use it to test if the median pH of a chemical solution is 7.0, or if the median score on a test is different from a national average of 80.

Assumptions of the Test

Interpreting the Results

The test works by calculating the differences between each data point and the hypothesized median, ranking the absolute values of these differences, and summing the ranks of the positive and negative differences. The output includes:


Frequently Asked Questions (FAQ)

Q1: How is the W statistic calculated manually?

The calculation follows these steps:

  1. For each data point \(x_i\), calculate the difference from the hypothesized median \(\eta_0\): \(d_i = x_i - \eta_0\).
  2. Discard any data points where the difference is zero. Let the remaining count be \(n\).
  3. Take the absolute value of each non-zero difference, \(|d_i|\).
  4. Rank these absolute differences from 1 (smallest) to \(n\) (largest), averaging ranks for any ties.
  5. Sum the ranks of the original positive differences to get \(W^+\).
  6. Sum the ranks of the original negative differences to get \(W^-\).
  7. The test statistic, \(W\), is the smaller of the two sums: \(W = \min(W^+, W^-)\).

Q2: What is the difference between the one-sample and paired-sample Wilcoxon tests?

Q3: How is the Z-approximation calculated for this test?

For larger sample sizes (e.g., \(n > 20\)), a normal approximation with a Z-score is used to find the p-value. The Z-score is calculated as:

$$ Z = \frac{W - \mu_W}{\sigma_W} $$

Where \(\mu_W\) is the mean and \(\sigma_W\) is the standard deviation of the W distribution:

Q4: What are the null and alternative hypotheses?

The hypotheses test the population median, denoted by \(\eta\), against the hypothesized median, \(\eta_0\):