[Verse 1]
When your sample's small and sigma's unknown
Thirty or less, you're not alone
The t-distribution comes to play
With fatter tails to light the way
Degrees of freedom, n minus one
Student's t-test gets the job done
[Chorus]
Z when you know, T when you don't
Sigma known? Then Z you won't postpone
Population standard deviation clear?
Z-test is the one you need here
But when sigma's just a guess
T-test handles all the rest
[Verse 2]
Sample size above thirty strong
Central limit makes nothing wrong
Even without sigma's true face
Z-test can take the normal's place
But stick to t when numbers are few
It's the conservative thing to do
[Chorus]
Z when you know, T when you don't
Sigma known? Then Z you won't postpone
Population standard deviation clear?
Z-test is the one you need here
But when sigma's just a guess
T-test handles all the rest
[Bridge]
One-sample, two-sample, paired or not
Check your assumptions on the spot
Independence, normality too
Random sampling must be true
Alpha level sets your risk
Point-zero-five is quite brisk
[Verse 3]
Hypothesis testing takes the stage
Null against alternative's rage
Calculate your test statistic now
Compare to critical, take a bow
P-value tells you what you need
Reject or fail, let logic lead
[Chorus]
Z when you know, T when you don't
Sigma known? Then Z you won't postpone
Population standard deviation clear?
Z-test is the one you need here
But when sigma's just a guess
T-test handles all the rest
[Outro]
Mean comparison made simple here
Choose your weapon, make it clear
T or Z, the choice is yours
Following statistical laws