Question
Maintaining swimming pools can be quite costly due to all the chlorine that is needed to keep the water clear and relatively free of germs.
Maintaining swimming pools can be quite costly due to all the chlorine that is needed to keep the water clear and relatively free of germs. A chain of hotels (all with outdoor pools) seeking to reduce the costs decided to analyse the factors that determine how much chlorine is needed. They commissioned a chemist to conduct an analysis. It is believed that the speed at which chlorine in a pool is depleted, measured by the percentage of Chlorine depletion during an 8-hour day, depends on the temperature of the water (C, higher temperature uses chlorine faster); on the pH level, which is a measure of the acidity of the water (pH level ranges from 0 to 14, at low levels the water is acidic at high levels it is alkaline, and levels around 7.5 use the least chlorine); and on weather (sunshine uses up chlorine). The chemist recorded chlorine depletion, water temperature, pH level and weather (defined as 1 for mainly cloudy, 2 for partly sunny, and 3 for sunny) on 210 8-hour days under varying conditions of pH level, water temperature and weather conditions. These data are saved in the a3e2.xlsx file.
(a) For each of the four variables, answer the following questions. Is it qualitative or quantitative? If it is qualitative, is it ranked or unranked? If it is quantitative, is it discrete or continuous? What is its level of measurement? Explain your answers.
(b) Consider the following three pairs of variables: depletion and temperature, depletion and pH, and depletion and weather. In each case, do you expect the variables to be related to each other? If yes, do you expect the relationship to be positive or negative, assuming that the pH level does not exceed 7.5? Explain your answers.
(c) Using R, calculate the Pearson or Spearman correlation coefficient, whichever is more appropriate, for the three pairs of variables in part (b). In each case, briefly explain your choice between the Pearson and Spearman correlation coefficients and comment on the direction and relative strength of the relationship as implied by the point estimate.
(d) Based on your answers in part (b), perform an appropriate test with R at the 5% significance level on each pair of variables to determine whether there is a linear, or at least monotonic, relationship between the variables in the expected direction. In each case, show the hypotheses and state the statistical decision and the conclusion.
(a) Using the subset() function1, divide the original data frame into three parts by the weather variable and denote the dataframe for mainly cloudy days (1) as c, the dataframe for partly sunny days (2) as p, and the dataframe for sunny days (3) as s. Show a screenshot of your Environment tab.
(b) Estimate the
depletioni 0 1temperaturei 2pHi i
multiple linear regression model three times, first for mainly cloudy days, then for partly sunny days, and finally for sunny days. Write out the sample regression equations using the actual variable names.
(c) For each of your regressions,
Interpret the adjusted coefficient of determination. Is the model likely to be useful in predicting the percentage of chlorine depletion over 8 hours? Explain your answer.
Test the overall significance of the model at the 5% significance level. What are the hypotheses, the statistical decision, and the conclusion? Be precise.
Based on your expectations in part (b) of Exercise 2, test appropriate hypotheses concerning the slope coefficients using t-tests at the 5% significance level. What are your decisions and conclusions?
Interpret the slope coefficients that you deemed significant in the expected direction.
(d) What do your three regressions suggest to you about the percentage of chlorine depletion over 8 hours on mainly cloudy days, on sunny days, and on partly sunny days? (Hint: compare the corresponding significant slope estimates to each other.)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started