1

I have fit a simple multiple linear regression model in R and printed the ANOVA output which looks like this:
R output

Is there a way to get the output to match the MINITAB ANOVA output:

MINITAB output

Dave2e
  • 22,192
  • 18
  • 42
  • 50
  • Can you provide a sample of your data? The differences is most like related to how the data is structured and the underlying assumptions. – Dave2e Jun 18 '22 at 19:38
  • @Dave2e There are no differences in the regression fit. The Minitab table has collapsed the "contributions" of the two predictors into one row. Therefore it's less informative and the R summary is better. – dipetkov Jun 19 '22 at 10:04
  • @Dave2e that data I used here is exactly the same. – Nadezhda Karkelanova Jun 19 '22 at 23:58

1 Answers1

1

I did not find anything about the default type of the ANOVA used in MINITAB, but most likely it is type III. R's anova does type I ANOVA, however. When you have no "interaction terms", you can achieve a type III ANOVA in R with drop1(..., test="F").

Explanation: type I ANOVA adds predictors one by one and tests the effect of their addition to the F statistic. Obviously, the result depends on the order in which the variables are added, i.e., anova(lm(y~x1+x2, data)) leads to different p-values than anova(lm(y~x2+x1, data)). To avoid this problem, type III ANOVA tests the effect on the F statistic with just one variable omitted.

Each ANOVA variant has its issues. Type I ANOVA can assign "statistical significance" to a variable or not depending on the position in the formula. Type III ANOVA, OTOH, can identify all predictors as "statistically insignificant" even for a good predictive model, e.g. in cases of (multi-)collinear variables.

cdalitz
  • 1,019
  • 1
  • 6
  • 7