Let m be the median lifespan.
1. Hypotheses:
H0:m=250
H1:m=250 (two-tailed test)
2. Calculate Differences and Ranks:
Sample size n=8. No values are equal to 250.
| Lifespan (x) | Difference (x-250) | |Difference| | Rank |
|---|---|---|---|---|
| 241 | -9 | 9 | 4 |
| 262 | +12 | 12 | 6 |
| 255 | +5 | 5 | 2 |
| 238 | -12 | 12 | 6 | (Tie with 262)
| 245 | -5 | 5 | 2 | (Tie with 255)
| 271 | +21 | 21 | 8 |
| 231 | -19 | 19 | 7 |
| 258 | +8 | 8 | 3 |
Handling ties: The absolute differences 5 and 5 would be ranks 1 and 2. Average is (1+2)/2=1.5. Oh wait, I made a mistake in my scratchpad. Let's re-rank properly.
Corrected Ranking:
Absolute differences in order: 5, 5, 8, 9, 12, 12, 19, 21.
Ranks to be assigned: 1, 2, 3, 4, 5, 6, 7, 8.
- The two '5's occupy ranks 1 and 2. Their rank is (1+2)/2=1.5.
- The '8' gets rank 3.
- The '9' gets rank 4.
- The two '12's occupy ranks 5 and 6. Their rank is (5+6)/2=5.5.
- The '19' gets rank 7.
- The '21' gets rank 8.
| Lifespan (x) | Difference (x-250) | |Difference| | Rank |
|---|---|---|---|---|
| 241 | -9 | 9 | 4 |
| 262 | +12 | 12 | 5.5 |
| 255 | +5 | 5 | 1.5 |
| 238 | -12 | 12 | 5.5 |
| 245 | -5 | 5 | 1.5 |
| 271 | +21 | 21 | 8 |
| 231 | -19 | 19 | 7 |
| 258 | +8 | 8 | 3 |
3. Sum Ranks and find Test Statistic:
W+ (sum of ranks for positive differences): 5.5+1.5+8+3=18
W− (sum of ranks for negative differences): 4+5.5+1.5+7=18
Check: W++W−=18+18=36. Also 21n(n+1)=21(8)(9)=36. Correct.
Test statistic W=min(W+,W−)=18.
4. Critical Value:
From MF19 tables for Wilcoxon signed-rank test, for a two-tailed test at 5% significance with n=8, the critical value is 3.
5. Conclusion:
We reject H0 if W≤ critical value. Here, 18>3. So we do not reject H0. There is insufficient evidence at the 5% level to suggest the median battery lifespan is different from 250 hours.