Statistics

P-Value Calculator

Convert a z or t statistic into a one-sided or two-sided p-value with an explicit alternative hypothesis.

Data stays on this deviceConvention explained below
Data explorer
Data explorer

Check the dataset and sample convention before interpreting results.

See the method

Add your observations

Runs on your device

Your statistical summary

Your result

Let’s calculate.

Use the Calculate button to see your result.

Review the method below for assumptions and conventions.

How to use this tool

  1. Enter reference distribution, test statistic, degrees of freedom (t only), alternative hypothesis, significance level.
  2. Select Calculate to view the result.
  3. Check the method and assumptions below before using the result.

Input reference and sample values

Use the units and choices shown for each field. Sample values are provided for practice, not as recommendations.

InputFormat and unitsSample
Reference distributionChoose Student t / Standard normal (z).Student t
Test statisticNumeric value.2
Degrees of freedom (t only)Numeric value. Minimum: 1. Maximum: 100000.20
Alternative hypothesisChoose Two-sided: different / One-sided: greater / One-sided: less.Two-sided: different
Significance levelNumeric value. Minimum: 0.0001. Maximum: 0.2.0.05

Result for these sample inputs

0.0592655354 probability
Test statistic
2
Degrees of freedom
20
Decision at chosen alpha
Do not reject the null hypothesis

The p-value is not the probability that the null hypothesis is true. Choose the hypothesis and significance level before inspecting the result; statistical significance does not measure practical importance.

Select Try the example in the form to load these values and calculate them again. This replaces the current form inputs. Compare the result with the method and worked explanation below.

The method, explained

Use the selected reference distribution to find the probability in the tail specified by the alternative. Two-sided probability doubles the tail beyond the absolute statistic.

A WORKED EXAMPLE

Using reference distribution = t, test statistic = 2, degrees of freedom (t only) = 20, alternative hypothesis = two, significance level = 0.05, the result is 0.0592655354 probability. Change these example inputs to match your task; use the method above to check each step.

What to keep in mind

The entered statistic must already be standardized under the null model. This tool does not validate the study design. A descriptive or probability calculation under the stated assumptions. Check the sample design and model before interpreting results.

Reference: NIST: statistical methods handbook

Common questions

Should I choose a one-sided or two-sided test?

Use two-sided when departures in either direction matter. Use a one-sided alternative only if its direction was chosen before seeing the data. Switching tails after inspecting a result changes the test.

Where do I get the test statistic?

A z or t statistic comes from a specified statistical test, not from a raw observation. Use the linked one-sample, paired or independent-sample test when you have observations rather than a standardized statistic.

Methodology maintained by ClarityKit. How these tools are built and checked.