Question: Can anyone help me with these? Need using R studio Need use R studio Show the code please. Thank you 2. Recall the zone out
Can anyone help me with these?
Need using R studio Need use R studio
Show the code please.
Thank you


2. Recall the zone out duration (ZOD) data we looked at in one of the regression lectures from Lesson 3. An additional experiment was conducted to look at the impact of sugary desserts eaten at lunch, two hours before class, and ZOD. Twelve students volunteered to participate in the experiment. Studenls were randomly assigned to eat a large slice of apple or cherry pie, with six participants randomized in each group. Two hours later, their ZODs (in minutes) were recorded during a 50-minute lecture. The data are in the le ZODTwoGroups.csv. a) Make a comparative boxplot for ZOD by pie type. Describe what you can get from the boxplots regarding the two distributions. Does there appear to be a difference between the ZODs for the two groups? b) Use sat. seed(12) and then create 1000 permutations for the difference of mean ZOD for cherry pie minus the mean ZOD for apple pie. What is the observed difference in means for the sample data? c) Write out the statistical hypotheses, using symbols, for testing that mean ZOD for cherry pie is greater than the mean ZOD for apple pie. (1) Make a histogram of the null distribution and add a vertical line for the observed sample di'erence. Set the number of bins to 13. Describe the shape of the null distribution and how the observed sample difference generally compares with the overall distribution. 6) Calculate the p-valuc for this permutation test. If you set up your code correctly, you should get a p-value of 0.002. What is the meaning of this p-value as a probability? i) What do you conclude for this hypothesis test in the context of the problem? Pie ZOD Apple INO Apple Apple 0.5 Apple 1.5 Apple Apple VNON- Cherry Cherry Cherry Cherry 5.5 Cherry 6.5 Cherry 5
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
