5 Hypothesis Tests and Confidence Intervals in the Simple Linear Regression Model
This chapter, continues our treatment of the simple linear regression model. The following subsections discuss how we may use our knowledge about the sampling distribution of the OLS estimator in order to make statements regarding its uncertainty.
These subsections cover the following topics:
Testing Hypotheses regarding regression coefficients.
Confidence intervals for regression coefficients.
Regression when \(X\) is a dummy variable.
Heteroskedasticity and Homoskedasticity.
The packages AER (Christian Kleiber & Zeileis, 2017) and scales (Wickham, 2017) are required for reproduction of the code chunks presented throughout this chapter. The package scales provides additional generic plot scaling methods. Make sure both packages are installed before you proceed. The safest way to do so is by checking whether the following code chunk executes without any errors.
library(AER)
library(scales)
References
Kleiber, C., & Zeileis, A. (2017). AER: Applied Econometrics with R (Version 1.2-5). Retrieved from https://CRAN.R-project.org/package=AER
Wickham, H. (2017). scales: Scale Functions for Visualization (Version 0.5.0). Retrieved from https://CRAN.R-project.org/package=scales