Challenge your conclusionLesson 25 of 30 · 7 min
The stopping rule is part of the test
Distinguish a fixed-sample test from stopping when a conventional p-value crosses a threshold.
A stopping rule says when data collection ends. A fixed-sample test evaluates the result after a planned sample size. Recomputing the same conventional p-value repeatedly and stopping as soon as it falls below 0.05 changes the false-positive behaviour.
The simulation has no mean effect. Compare one test at the final sample size with the rule 'report success if any of these interim tests crosses 0.05'. The interim tests share observations and are dependent, so the independent-test formula from the previous lesson does not apply.
This example compares two rules on the same simulated data. For a planned experiment, choose a final count or a method that accounts for interim decisions. Record interruptions and changes to the plan.
Can dependent interim checks still inflate the chance of at least one threshold crossing?
Write a prediction (optional)
Run the prepared example
This page puts the example in the Python editor. Select Run Python with the code unchanged.
Seeded simulation
A saved draft is open. To run the published example, open Editor tools and select Restore example. Recover draft brings your code back.
Execution error
Technical error details
What to compare
Compare Fixed final-test rejection fraction with Any interim crossing fraction. Both use the same simulated observations. Which rule gives itself more chances to claim a discovery?
Your result
Result tools
The interim rule can count an early threshold crossing even if the final test does not reject. Its checks reuse observations.
Published example output
The site ran the original code to produce this reference. Build environment ↗
Fixed final-test rejection fraction: 0.05 Any interim crossing fraction: 0.15 Planned observation counts: [20, 40, 60, 80, 100]
The interim rule can count an early threshold crossing even if the final test does not reject. Its checks reuse observations.
Change and run again
In the Python editor, replace looks = [20, 40, 60, 80, 100] with looks = [100] and select Run Python. Then use looks = list(range(10, 101, 10)) and run again. Compare Any interim crossing fraction with Fixed final-test rejection fraction. Why do the ten checks share observations? Return to the Python editor
What this example supports. The simulation illustrates one optional-stopping rule. It neither estimates the error rate of every sequential design nor supplies a valid sequential test.
Try a fresh case
A team adds ten more observations whenever p is above 0.05 and stops at the first success. What is the issue?
Hints for this question
- Compare the advertised procedure with the one actually followed.
- The stopping decision uses the same evidence being tested.