Introdução à ANOVA

library(tidyverse)
milho = read.csv("./data/milho.csv")
milho = as_tibble(milho)

teste_aov = aov(Colheita ~ Variedade, data = milho)
teste_aov
## Call:
##    aov(formula = Colheita ~ Variedade, data = milho)
## 
## Terms:
##                 Variedade Residuals
## Sum of Squares     56.375    34.500
## Deg. of Freedom         3         4
## 
## Residual standard error: 2.936835
## Estimated effects may be unbalanced
teste_tukey = TukeyHSD(x = teste_aov,
                       c("Variedade"),
                       conf.level=0.9)
teste_tukey
##   Tukey multiple comparisons of means
##     90% family-wise confidence level
## 
## Fit: aov(formula = Colheita ~ Variedade, data = milho)
## 
## $Variedade
##     diff        lwr       upr     p adj
## B-A  2.5  -7.024103 12.024103 0.8291950
## C-A -1.5 -11.024103  8.024103 0.9522488
## D-A  5.5  -4.024103 15.024103 0.3636471
## C-B -4.0 -13.524103  5.524103 0.5778444
## D-B  3.0  -6.524103 12.524103 0.7479312
## D-C  7.0  -2.524103 16.524103 0.2222893
agua = read.csv("./data/agua.csv")
agua = as.tibble(agua)
## Warning: `as.tibble()` was deprecated in tibble 2.0.0.
## Please use `as_tibble()` instead.
## The signature and semantics have changed, see `?as_tibble`.
## This warning is displayed once every 8 hours.
## Call `lifecycle::last_lifecycle_warnings()` to see where this warning was generated.
teste_aov = aov(Tempo ~ Tipo, data = agua)
teste_aov
## Call:
##    aov(formula = Tempo ~ Tipo, data = agua)
## 
## Terms:
##                     Tipo Residuals
## Sum of Squares  102.0833  236.1667
## Deg. of Freedom        1        10
## 
## Residual standard error: 4.859698
## Estimated effects may be unbalanced
#teste_tukey = TukeyHSD(x = teste_aov,
#                       c("Variedade"),
#                       conf.level=0.9)
#teste_tukey
Previous