Statistics
Shuffle the Groups
Could a seven-centimeter advantage come from the assignment alone?
Compare the original group means. Shuffle the labels once, then 1,000 times. Compare the simulated tail proportion with all possible assignments.
Paper frog jumps
In this fictional experiment, a class randomly assigns folded frogs to a wide or narrow final crease. Each frog jumps once under the same launch procedure. The response is jump distance in centimeters.
Add shuffles to keep drawing from the current run. Clear shuffles starts a fresh run. Select Fix seed in the settings to replay it.
Last shuffled groups
Change distances or seed
Enter up to eight jumps per group. Match your measurements to a tenth of a centimeter. Each entry represents one frog, including tied distances.
Differences under the sharp null
Assume the crease has zero effect on every frog. Reassign the observed distances to groups of the original sizes. Each assignment of labeled frogs is equally likely.
Graph values
| Gap interval¹ | Other | Extreme |
|---|
¹Both endpoints are included. Values displayed to four decimal places where needed.
Classroom investigation and interpretation
Start with the one-sided “farther” alternative. Which sets of four frogs could produce a gap at least as large as the original? Change the alternative to “either way.” Predict what will happen to the reference probability, then try an example with unequal group sizes.
The statistic is the wide-crease mean minus the narrow-crease mean. Under the sharp null the treatment labels can change while each frog’s distance stays fixed. This test assumes complete random assignment with fixed group sizes. It uses the assignment mechanism from the experiment.
For “farther,” count differences greater than or equal to the observed difference. For “less far,” count differences less than or equal to it. For “either way,” compare absolute differences. All three rules include ties. Change the alternative here to teach the distinction; in an actual analysis, specify it in advance.
The exact p-value counts extreme assignments divided by all possible assignments. The simulated proportion estimates that probability and can be zero in a small run. A small p-value indicates that the observed difference would be unusual under this null and assignment procedure.