##DESCRIPTION ##KEYWORDS('small sample','hypothesis testing','statistics') ## ##ENDDESCRIPTION DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PG.pl", "PGbasicmacros.pl", "PGchoicemacros.pl", "PGanswermacros.pl", "PGnumericalmacros.pl", "PGstatisticsmacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $n = random(3,20,1); $mean = random(80,95,1); $s = random(5,15,1); $eff = random(90,99,1); $e = $eff/100; $alpha = random(.01,.05,.04); $m = $mean/100; $s1 = $s/100; $df = $n-1; $t = tdistr($df, $alpha); $test = ($m-$e)/($s1/sqrt $n); $mc = new_multiple_choice(); @ans = ("We can reject the null hypothesis that \( \mu = $e\) and accept that \( \mu > $e\), that is, the bug repellent is effective. ", "There is not sufficient evidence to reject the null hypothesis that \( \mu = $e\). "); if ($test > $t ) {$tag = 0;} else {$tag = 1;} $mc -> qa('The final conclustion is', $ans[$tag]); $mc -> extra($ans[1-$tag]); BEGIN_TEXT The effectiveness of a new bug repellent is tested on \($n\) subjects for a 10 hour period. Based on the number and location of the bug bites, the percentage of surface area exposed protected from bites was calculated for each of the subjects. The results were as follows: $PAR \( \overline{x} = $mean \) $PERCENT, \( \ s = $s \)$PERCENT $PAR The new repellent is considered effective if it provides a percent repellency of at least \($eff\). Using \(\alpha = $alpha \), construct a hypothesis test with null hypothesis \(\mu = $e\) and alternative hypothesis \(\mu>$e\) to determine whether the mean repellency of the new bug relellent is greater than \($eff\) by computing the following: $PAR (a) \( \ \) the degree of freedom \( \ \) \{ans_rule(10)\} $PAR (b) \( \ \) the critical \(t\) value \( \ \) \{ans_rule(10)\} $PAR (c) \( \ \) the test statistics \( \ \) \{ans_rule(10)\} $PAR $PAR \{ $mc->print_q() \} $PAR \{ $mc->print_a() \} END_TEXT ANS(num_cmp($df)); ANS(num_cmp($t, tol=>.002)); ANS(num_cmp($test)); ANS(radio_cmp($mc->correct_ans)); ENDDOCUMENT(); # This should be the last executable line in the problem.