usair_2023.txt SO2 temp wind.speed annual.precip days.precip 10 70.3 6 7.05 36 13 61 8.2 48.52 100 12
Question:
usair_2023.txt
SO2 temp wind.speed annual.precip days.precip 10 70.3 6 7.05 36 13 61 8.2 48.52 100 12 56.7 8.7 20.66 67 17 51.9 9 12.95 86 56 49.1 9 43.37 127 36 54 9 40.25 114 29 57.3 9.3 38.89 111 14 68.4 8.8 54.47 116 10 75.5 9 59.8 128 24 61.5 9.1 48.34 115 110 50.6 10.4 34.44 122 28 52.3 9.7 38.74 121 17 49 11.2 30.85 103 8 56.6 12.7 30.58 82 30 55.6 8.3 43.11 123 9 68.3 8.4 56.77 113 47 55 9.6 41.31 111 35 49.9 10.1 30.96 129 29 43.5 10.6 25.94 137 14 54.5 10 37 99 56 55.9 9.5 35.89 105 14 51.5 10.9 30.18 98 11 56.8 8.9 7.77 58 46 47.6 8.8 33.36 135 11 47.1 12.4 36.11 166 23 54 7.1 39.04 132 65 49.7 10.9 34.99 155 26 51.5 8.6 37.01 134 69 54.6 9.6 39.93 115 61 50.4 9.4 36.22 147 94 50 10.6 42.75 125 10 61.6 9.2 49.1 105 18 59.4 7.9 46 119 9 66.2 10.9 35.94 78 10 68.9 10.8 48.19 103 28 51 8.7 15.17 89 31 59.3 10.6 44.68 116 26 57.8 7.6 42.59 115 29 51.1 9.4 38.79 164
Question 1 [33 marks]
Read in the 'usair_2023.dat' data to R and save as a data frame. Provide R code, output and written interpretation for parts a) to d) of this question. Assume all variables meet MVN and other test assumptions for the purpose of these exercises.
a). In order to answer this question you will need to have read the additional notes available in the Week 6 block on the Study Desk called "Notes-on-FA-GoF-tests-and-degrees-offreedom.pdf". Complete the Table below (2 marks). What is the maximum number of factors that you think could be fit to this data and why? (2 marks)? (4 marks total) factor Initial df F1 F2 F3 F4 F5 dof from formula
b). Perform a Factor Analysis using the 'factanal' function for a 2-factor solution based on all five original variables (apply no rotation). Provide output and interpretation for: (14 marks total): Variance explained (3 marks) Chi-square test (3 marks) Variable loadings (consider only loadings greater than |0.5|) (4 marks) Difference in uniqueness values for the variables temp and wind speed (3 marks). Provide a definition of uniqueness (1 mark).
c). Repeat the FA with a varimax rotation and calculate the communalities. Provide output and interpret: (8 marks total) Changes in the variable loadings (3 marks) The communalities (2 marks). Also provide a definition of communality (1 mark) In general, how does a rotation affect the results of loadings (1 mark), %variance explained and the chi square test (1 mark)?
d). Perform parallel analysis using a seed value of 132 and 500 iterations. From this analysis find the observed eigenvalues, mean values and 95th percentile values of the simulated data and complete the table below (1 mark). Produce the scree plot for the PC results only and include error bars (1 mark). Use all of this this information to explain how many factors should be interpreted (2 marks). (4 marks total) F1 F2 F3 F4 F5 eigenvalue observed simulated mean simulated 95th percentile
e). Explain in your own words the aim of parallel analysis (1 mark) and how the parallel analysis works (2 marks). (3 marks total