question 1 and 2, use Rstudio to attempt themand question 3 by hand
Lab Assignment 2 new MATH2203: Lab Assignment 2 (worth 15%) Due date: As shown on canvas 1. (Data: "asphalt.mtw") The data (n = 31) deals with pavement durability which contains measurements o n the following variables: y x1 = = change in rut depth viscosity of rut depth x2 = % of asphalt in the surface course x3 = % of asphalt in the base course x4 = % of fines in the surface course x5 = % of voids in the surface course x6 = run indicator x6 is a run indicator which separates the data into two different experimental runs. (a) Fit the full regression model with six predictors to the data set and use the ANOVA table to assess its overall fit. (b) Exhibit the fitted equation for y when the run indicator is 1 and when it is -1. (c) Use All Possible Subsets regression to select the best model based on their R2 values. Perform all diagnostic tests and check the adequacy of this model. 2. (Data: "byssinosis.mtw") The data were collected from a group of workers in the cotton industry to assess the prevalence of the lung disease byssinosis among these workers. This disease is caused by long term exposure to particles of cotton, hemp, flax and jute working in this type of environment. It can result in asthma-like symptom which can lead to death among sufferers. The response variable y is binary and refers to number of workers suffering (response = yes) and not suffering (response = no) and the predictors are: xl = dustiness of the workplace (1 = high, 2 = medium, 3 = low) x2 = race ( 1 = European, 2 = other) x3 = sex ( 1 = male, 2 = female) x4 = smoking history (1 = smoker, 2 = nonsmoker) x5 = length of employment in the cotton industry (1 = less than 10 years, 2 = between 10 and 20 years, 3 = more than 20 years) Notice that all five predictors are qualitative variables and the responses are entered in the event/trial format. (a) Fit a logistic regression model to the data set and discuss which of the predictors have a significant effect on the presence of byssinosis. (b) Discuss the adequacy of the logistic regression model. (c) (Needs to be done manually or by hand) From the final model you have selected in part (a), determine the probability that a person will suffer from byssinosis if given: i. xl = 2, x2 = 2, x3 = 1, x4 = 2, x5 = 3, ii. xl = 1, x2 = 2, x3 = 2, x4 = 1, x5 = 3, iii. xl = 2, x2 = 1, x3 = 1, x4 = 2, x5 = 2, iv. xl = 3, x2 = 1, x3 = 2, x4 = 2, x5 = 1. 3. An industrial engineer is investigating the effects of four assembly methods (A, B, C, and D) on the assembly time for a color television component. Four operators are selected for the study. Furthermore, the engineer knows that each assembly method produces such fatigue that the time required for the last assembly may be greater than the time required for the first, regardless of the method. That is, a trend develops in the required assembly time. The engineer suspects that the workplaces used by the four operators may represent an additional source of variation. A fourth factor, workplace (α, β, γ, δ) needs to be considered and another experiment is conducted. The layout of the experiment and the data are given in the following. Assembly 1 2 3 4 1 Cβ=11 Bγ=10 Dδ=14 Aα=8 (a) What design is employed in this experiment? why? (b) Test if the four assembly methods are different. Use α = 5%. (c) Test i f there is a difference between the four assembly methods. State the hypotheses and use α = 5%. (d) Obtain the estimates of the treatment effects. (e) Use Tukey’s method to perform pairwise comparison. (f) Check assumptions. byssinosis.mtw BysYesBysNoTotalDustRaceSexSmokeEmploy 3374011111 0747421111 225826031111 2513916412111 0888822111 324224532111 05511211 1939421211 318018331211 2222412211 214514722211 326026332211 0161611121 0353521121 013413431121 6758112121 1474822121 112212332121 04411221 1545521221 216917131221 1242512221 314214522221 430130532221 8212911112 1505121112 118718831112 8303812112 05522112 0333332112 00011212 1333421212 2949631212 00012212 04422212 03332212 281011122 1161721122 0585831122 191012122 00022122 07732122 00011222 0303021222 1909131222 00012222 04422222 04432222 317710811113 114114221113 1249550731113 10314112113 01122113 0454532113 01111213 3919421213 317617931213 01112213 00022213 02232213 5475211123 0393921123 318218531123 3151812123 01122123 0232332123 02211223 318719021223 234034231223 00012223 02222223 03332223