# NOT RUN {
T1 <- xtabs(~ station + passed, data = Inspect)
T1
barplot(T1, beside = TRUE, legend = TRUE)
chisq.test(T1)
rm(T1)
# }
# NOT RUN {
library(ggplot2)
ggplot2::ggplot(data = Inspect, aes(x = passed, fill = station)) +
geom_bar(position = "dodge") +
theme_bw()
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab