OLS Diagnostics in R
OLS Diagnostics: Error Variance Variance
• Formal tests for heteroskedasticity are available from the lmtest
library
– library(lmtest)
– bptest(ols.model1) will give you the Breusch‐Pagan test stat
– gqtest(ols.model1) (ols.model1) will give you the Goldfeld Goldfeld‐Quandttest Quandttest stat
– hmctest(ols.model1) will give you the Harrison‐McCabe test stat