STAT 541: Sample size calculations

# Statistics 541: Sample size calculations

## Admistrivia

• Handout for homework

## Sample size calculations

### Simulating an experiment

• Need to simulate a whole experiment in our heads
• Suppose we are testing H0: mu = 0 vs. H1: mu > 0
• Collect n samples, compute X-bar, SD(X-bar) = sigma/sqrt(n)
• Draw pictures under null and under alternative
• Rejection region defines alpha
• Acceptance region defines beta under alternative
• Goal:
• want mu to be small so we can detect subtle differences
• want alpha to be small so no type I errors
• want beta to be small so no type II errors
• want n to be small so we don't have to collect much data
• Problem: ALL of these are playing agisnst each other

### Picking n

The one sample problem. Is x-bar signficantly larger than a specified null value?
• Alpha says how far away x-bar has to be to be significant
• Beta for some delta says how far away x-bar has to be from interesting point
• Draw picture on Z-scale
• Put "real" scale underneath it
• n determines ratio of two scales
• Ah, now the details begin
• delta = mu - mu0
• Zalpha = required significance (alpha)
• Zbeta = required power (beta)
• Key equation: |Zalpha| + |Zalpha| = delta/SE
• n = sigma2 (|Zalpha| + |Zalpha|)2/delta2
Easier problem: Find n to work with a confidence interval. n = |Zalpha| sigma2 /(Interval width)2. Depending how you define width, you many need a factor of 2 in here also.

### Picking all values

Need to pick all parameters.
• Draw up table of type I and type II error
• specify delta via economics (smallest profitable difference)
• put costs on each error cell
• If null is true, want small alpha, if alternative is true want small beta, unfortunately, this would be self-confirming EVEN if it weren't correct.
• Scientific tradition: alpha = .05, beta = .1 or beta = .2
• economic decisions are more difficult
• Example: to build a new plant or not
• if everything works, small profits
• if not enough new jobs, large loss
• Must protect null (alpha very small)
• Example: eliminate night shift to cut down on breakdowns
• if alternative true, big wins
• if alternative shown untrue, we missed a few overtime jobs
• more symetric (alpha approximately = beta, both not too small)
• Now solve for n

Last modified: Tue Apr 3 08:50:07 2001