---
title: "Setting Up a Hypothesis Test"
description: "State a null and an alternative hypothesis about a population, fix a significance level before looking at the data, and decide in advance what result would count as surprising enough to reject the nul"
canonical: https://lightmysky.com/learn/mathematics/setting-up-a-hypothesis-test-mt_JmpLNHK0Nf
source: https://lightmysky.com/learn/mathematics/setting-up-a-hypothesis-test-mt_JmpLNHK0Nf.md
retrieved: 2026-11-12
---

> **Agent view.** This is the Markdown twin of the page, for tools and assistants.
> When to use this site, and the call that answers each job: https://lightmysky.com/agent-instructions.md
> API description (OpenAPI 3.1): https://lightmysky.com/openapi.json · Authentication: https://lightmysky.com/auth.md
> Pricing: https://lightmysky.com/pricing.md · Catalog: https://lightmysky.com/llms.txt · Full catalog: https://lightmysky.com/llms-full.txt
> Every machine-readable file on this domain: https://lightmysky.com/.well-known/ai-catalog.json
> Ask for Markdown with `Accept: text/markdown`, a `.md` address, or `?mode=agent`.

# Setting Up a Hypothesis Test

State a null and an alternative hypothesis about a population, fix a significance level before looking at the data, and decide in advance what result would count as surprising enough to reject the null.

Subject: Mathematics · Area: Data & Statistics · Ages 17 to 18
Page: https://lightmysky.com/learn/mathematics/setting-up-a-hypothesis-test-mt_JmpLNHK0Nf

## Ready when they can

- Write null and alternative hypotheses for a stated claim
- Decide whether the test is one-tailed or two-tailed and say why
- Describe Type I and Type II errors in context and interpret significance level without treating it as the probability that H0 is true

## Lesson: Innocent until the data object

Hypotheses concern population parameters, such as the mean μ or a probability p, not an observed sample mean. H0 is the null hypothesis; H1 is the alternative. These examples write H0 with equality at the tested value. A one-sided null can instead include that boundary, such as μ ≤ 45 against μ > 45. H1 uses >, < or ≠, where ≠ means not equal. State the parameter, hypotheses and test plan before examining the results.

**Example.** For a claim that a coin favours heads, let p be its probability of heads. Use H0: p = 0.5 and H1: p > 0.5. Larger head counts support H1, so this is an upper-tail test. For a claim that a population mean is below a target, H1 uses < and the test uses the lower tail. Direction comes from the planned question, not whichever direction the sample happens to take.

*(drawing: The order matters. Choosing the direction after seeing the result changes the planned test.)*

Choose significance level α before examining results. A valid level-α test has probability at most α of rejecting H0 when H0 is true. The actual rate can be smaller, especially with discrete outcomes. A Type I error rejects a true H0. A Type II error fails to reject a false H0. Neither type of error implies that the population changed during the test. α is not the probability that H0 is true.

An alternative such as μ ≠ 24 allows departures below or above 24, so it is two-tailed. In an equal-tail test with a continuous null distribution, each rejection tail has probability α / 2. For α = 0.08, each gets 0.04. For disjoint rejection tails, add their probabilities to find the total under H0. Other designs need not split the level equally. Plan the region using the chosen statistic's distribution under H0.

For H0: μ = 200 g against μ ≠ 200 g, a Type I error is reporting a departure when the population mean really is 200 g. A Type II error is missing a departure that exists. Failing to reject H0 does not prove it true. With the same sample size and a smaller rejection region, false alarms become less likely, but a real departure can become easier to miss.

**Recap.** State population hypotheses and plan the tails and significance level before examining data. Type I rejects a true H0; Type II misses a false H0. Failing to reject does not prove H0.

*Lesson, worked questions and flashcards authored for this learning dataset.*

## Practice

18 questions on this page, each with its working shown.

## Needs first

- [Sampling Distributions and the Central Limit Theorem](https://lightmysky.com/learn/mathematics/sampling-distributions-and-the-central-limit-theorem-mt_nugaEeUSii)

## Optional connections

- [Conditional Probability from Tables and Venn Diagrams](https://lightmysky.com/learn/mathematics/conditional-probability-from-tables-and-venn-diagrams-mt_Vx88ugViYP)

## Opens up

- [Significance Tests for Chemical Data](https://lightmysky.com/learn/science/significance-tests-for-chemical-data-mt_2-SDgPjOQk)
- [Beyond Accuracy: Precision, Recall and the Cost of an Error](https://lightmysky.com/learn/computing/beyond-accuracy-precision-recall-and-the-cost-of-an-error-mt_BHGgZM7tak)
- [Hypothesis Tests for a Mean with the t-Distribution](https://lightmysky.com/learn/mathematics/hypothesis-tests-for-a-mean-with-the-t-distribution-mt_ig2o39hAwh)
- [Testing a Binomial Proportion](https://lightmysky.com/learn/mathematics/testing-a-binomial-proportion-mt_ZJ8MTLYYKE)
