Last compiled: Mar 02, 2021

Introductions

  • In our presentation, we decided to look at the quality of red wines from the UCI repository. Wine quality has many different factors, and we aim to figure out which of those factors affect the quality of the wine the most.

  • The link to the dataset can be found here http://archive.ics.uci.edu/ml/datasets/Wine+Quality.

Code

lm(density ~ sulphates, data = reds)
lm(density ~ `citric acid`, data = reds)
lm(density ~`volatile acidity`, data = reds)
lm(sulphates ~ `citric acid`, data = reds)
lm(sulphates ~ `volatile acidity`, data = reds) 

plots <- ggplot(reds, aes(`variable_name`, quality))+
  geom_point(position = "jitter") +
  geom_smooth(method = lm, se = FALSE)+ 
  labs(x = "Variable_name", y = "Wine Quality",
      title = "How variable_name Effects Wine Quality")

Citric Acid

Sulphates

Volatile Acidity

Density

Multiple Linear Regression

winehonhonhon <- lm(quality ~ sulphates + density +
`citric acid` + `volatile acidity`, data = reds)
##        1        2        3        4        5        6 
## 5.117634 5.088691 5.213229 5.878899 5.117634 5.169021
## [1] 5 5 5 6 5 5