ALY 6015 Northeastern University Hypothesis Tests in R

Summary:Complete the following problems using R and/or MS Excel. Be sure to show your work and include the hypothesis tests, the critical values, the computed test values, and the resulting decisions where applicable.Perform the following steps.State the hypotheses and identify the claim.Find the critical value.Compute the test value.Make the decision.Summarize the results.Use the traditional method of hypothesis testing unless otherwise specified. Assume all assumptions are met.1.Blood Types:A medical researcher wishes to see if hospital patients in a large hospital have the same blood type distribution as those in the general population. The distribution for the general population is as follows: type A, 20%; type B, 28%; type O, 36%; and type AB = 16%. He selects a random sample of 50 patients and finds the following: 12 have type A blood, 8 have type B, 24 have type O, and 6 have type AB blood.At α = 0.10, can it be concluded that the distribution is the same as that of the general population?2.one time performance by airlines According to the Bureau of Transportation Statistics, on-time performance by the airlines is described as follows:Action% of TimeOn time70.8National Aviation System delay8.2Aircraft arriving late9.0Other (because of weather and other conditions)12.0Records of 200 randomly selected flights for a major airline company showed that 125 planes were on time; 40 were delayed because of weather, 10 because of a National Aviation System delay, and the rest because of arriving late. At α = 0.05, do these results differ from the government’s statistics?3.his table lists the numbers of officers and enlisted personnel for women in the military. At α = 0.05, is there sufficient evidence to conclude that a relationship exists between rank and branch of the Armed Forces?ActionOfficersEnlistedArmy10,79162,491Navy7,81642,750Marine Corps9329,525Air Force11,81954,3444.Are movie admissions related to ethnicity? A 2014 study indicated the following numbers of admissions (in thousands) for two different years. At the 0.05 level of significance, can it be concluded that movie attendance by year was dependent upon ethnicity?CaucasianHispanicAfrican AmericanOther201372433517410720143702921521405.The amount of sodium (in milligrams) in one serving for a random sample of three different kinds of foods is listed. At the 0.05 level of significance, is there sufficient evidence to conclude that a difference in mean sodium amounts exists among condiments, cereals, and desserts?CondimentsCerealsDesserts27026010013022018023029025018029025080200300703203602001403001606.The sales in millions of dollars for a year of a sample of leading companies are shown. At α = 0.01, is there a significant difference in the means?CerealChocolate CandyCoffee5783112613201061852641093022491256892371737.The expenditures (in dollars) per pupil for states in three sections of the country are listed. Using α = 0.05, can you conclude that there is a difference in means?undefinedEastern thirdMiddle thirdWestern third49466149528259537451860562026000652872436479691161138.A gardening company is testing new ways to improve plant growth. Twelve plants are randomly selected and exposed to a combination of two factors, a “Grow-light” in two different strengths and a plant food supplement with different mineral supplements. After a number of days, the plants are measured for growth, and the results (in inches) are put into the appropriate boxes.Grow-light 1Grow-light 2Plant food A9.2, 9.4, 8.98.5, 9.2, 8.9Plant food B7.1, 7.2, 8.55.5, 5.8, 7.6Can an interaction between the two factors be concluded? Is there a difference in mean growth with respect to light? With respect to plant food? Use α = 0.05.On Your OwnUse R to complete the following steps. Be sure to include all code in an appendix at the end of your submission. Assume the expected frequencies are equal and α = 0.05.Use the following data sets: baseball.csv crop_data.csvDownload the file ‘baseball.csv’ from above and import the file into R.Perform EDA on the imported data set. Write a paragraph or two to describe the data set using descriptive statistics and plots. Are there any trends or anything of interest to discuss?Assuming the expected frequencies are equal, perform a Chi-Square Goodness-of-Fit test to determine if there is a difference in the number of wins by decade. Be sure to include the following:State the hypotheses and identify the claim.Find the critical value (α = 0.05) (From table in the book).Compute the test value.Make the decision. Clearly state if the null hypothesis should or should not be rejected and why.Does comparing the critical value with the test value provide the same result as comparing the p-value from R with the significance level?Here is some code to get you started. Be sure to import the dplyr and tidyverse packages.# Extract decade from year bb$Decade <- bb$Year - (bb$Year %% 10)# Create a wins table by summing the wins by decade wins <- bb %>% group_by(Decade) %>% summarize(wins = sum(W)) %>% as.tibble()Download the file ‘crop_data.csv’ from above and import the file into R.Perform a Two-way ANOVA test using yield as the dependent variable and fertilizer and density as the independent variables. Explain the results of the test. Is there reason to believe that fertilizer and density have an impact on yield?** Be sure to convert the variables density, fertilizer and block to R factors.**Include a null and alternate hypothesis for both factors and the interaction.