Single Factor ANOVA is a method we use when we want to compare a quantitative variable among more than two categories. It evaluates whether the means of different treatment groups, or populations, are equivalent. When we only have two populations then we can perform a two-sample t procedure, but when we have more populations we need to examine the data with Single Factor ANOVA.
In the R script DA7_Single_Factor_ANOVA.R follow along with the analysis that compares average number of roommates between majors for the current term of ST314 students. You will need to upload the data from the student information dataset.
Once you have reviewed the example analysis, conduct your own by choosing one of the following three options:
Option 1: Is there evidence average anticipated staring salary differs between majors for ST314 students?
Option 2: Is there evidence average amount spent on school materials differs between majors for ST314 students?
Option 3: Is there evidence average number of emails received differs between majors for ST314 students?
For the option you selected, answer the questions below. Use a significance level of 0.10.
a. Create side-by-side boxplot of the data and add color and a title to your plot. Paste your plot.
b. From the side-by-side box plot, does there look to be a difference between the averages? Explain your reasoning.
c. State the appropriate null and alternative hypothesis for the Single Factor ANOVA F test.
d. State the conditions for the Single Factor ANOVA F Test. Is it reasonable to seem that these conditions are satisfied? If not, still proceed.
e. Perform the Single Factor ANOVA F test in R.
1. Paste the ANOVA table.
2. From the ANOVA table, what is the average between group variability and the average within group variability, respectively the MSTr and MSE?
f. Use the F statistic and p-value from the ANOVA table to state whether there is a significant difference between at least two of the group means.
1. (2 points) State whether to reject the null. State the test statistic and p-value.
2. (2 points) Include a statement of the strength of evidence in terms of the alternative. Include context.
g. Using the Tukey’s Multiple Comparison procedure output. Are there any individual comparisons that are significant at the 0.10 significance level?
1. Paste R output for the multiple comparisons procedure.
2. List all comparisons that are significant (or state those that are not).
3. Interpret the 90% F-W confidence interval for the difference with the smallest p-value (even if it is not significant).
# R code and explanation for data analysis 6.
# Read in the Student Information Data. Call it st314data.
st314data= read.csv(file.choose(), header = TRUE)
# gives variable names.
names(st314data) # gives variable names.
levels(st314data$Major) # gives group names for majors
# This analysis compares number of roommates among majors of ST314 students.
# Follow along with my code.
# For your own analysis choose your own variable to compare within majors.
# Create a side-by-side boxplot to compare number of roommates among the different majors.
# Expand the plot if you can't see the group names.
# add a title with main = "title" and a vertical axis title using ylab = "title".
# color can be added with the rainbow commmand or blues9, or by assigning a specific color like "yellow"
boxplot(Roommates~Major, data = st314data, main = "Comparison between Major and Number of Roommates
for ST314 Students", ylab = "Number of roommmates", col = rainbow(5))
# Find the mean, sd and group sizes using the aggregate command....
By purchasing this solution you'll be able to access the following files: