Homework 6 – Due Tuesday, November 10 at 11:59PM1.[4pt]
Do problem 7.12 on p 261 ofOpenIntro.But make this change to part a): Your alternativehypothesis should be that the police officers have ahigherconcentration of lead than thepeople with no exposure.2.[2pt]Therockdataset inRcontains measurements on a sample of rocks. Assume this is arandom sample. Perform at-test onrock$areato determine whether this sample comesfrom a population whose mean area isdifferent from7000(units are pixels2, I think).(a)What is thet-statistic?(b)What are the degrees of freedom?(c)What is the p-value? What conclusion do you make based on this p-value?(d)Provide a one-sentence interpretation of the confidence interval from the test.3.[3pt]Complete a table like the one below by doing the following:i. Make a placeholder vector of10000zeros. This code will store the vector asp:p <- rep(0,10000)ii. Write afor()loop of10000iterations. Inside the loop, draw a random sample of sizenfrom aN(5,2)distribution and perform a two-sidedt-test on the sample:H0:μ=5HA:μ≠5uset.test(rnorm(n,5,2), mu=5)$p.valueto extract the p-value. Store thep-value in theithposition of your placeholder vector.iii. Run the loop. When it’s over, you should have a vector of10000p-values. The commandsum(p <= 0.05)/10000will find the proportion of p-values that are less than orequal to0.05. Find the proportion of p-values that are less than0.05, as well as those lessthan0.01.Proportion of p-values≤0.05Proportion of p-values≤0.01n=20n=40n=100If the significance level is0.05, you should reject the null hypothesis when it’s true0.05of the time. Is this what’s happening?
4.[3pt]Repeat the previous exercise, but change the mean of the normal distribution fromwhich you’re sampling to4.(a)Continue to testH0:μ=5HA:μ≠5Proportion of p-values≤0.05Proportion of p-values≤0.01n=20n=40n=100(b)Is the null hypothesis true in this case?(c)Does the sample size seem to affect the Type2error rate? How?
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.
Read moreEach paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.
Read moreThanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.
Read moreYour email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.
Read moreBy sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.
Read more
Recent Comments