Course Outline
-
segmentGetting Started (Don't Skip This Part)
-
segmentStatistics and Data Science: A Modeling Approach
-
segmentPART I: EXPLORING VARIATION
-
segmentChapter 1 - Welcome to Statistics: A Modeling Approach
-
segmentChapter 2 - Understanding Data
-
segmentChapter 3 - Examining Distributions
-
segmentChapter 4 - Explaining Variation
-
segmentPART II: MODELING VARIATION
-
segmentChapter 5 - A Simple Model
-
segmentChapter 6 - Quantifying Error
-
segmentChapter 7 - Adding an Explanatory Variable to the Model
-
segmentChapter 8 - Digging Deeper into Group Models
-
segmentChapter 9 - Models with a Quantitative Explanatory Variable
-
9.2 Specifying the Height Model with GLM Notation
-
segmentPART III: EVALUATING MODELS
-
segmentChapter 10 - The Logic of Inference
-
segmentChapter 11 - Model Comparison with F
-
segmentChapter 12 - Parameter Estimation and Confidence Intervals
-
segmentFinishing Up (Don't Skip This Part!)
-
segmentResources
list High School / Advanced Statistics and Data Science I (ABC)
9.2 Specifying the Height Model with GLM Notation
Here is how we specify a regression model in which we have a single quantitative explanatory variable (such as Height
):
It might be useful to compare this notation to that used in the previous chapter to specify the two-group model (such as Height2Group
):
The fact that the same notation represents both models is what is so beautiful about the General Linear Model. It is simple and elegant and can be applied across a wide variety of situations, including situations with categorical or quantitative explanatory variables. Although both models are specified using the same notation, the interpretation of the notation varies from situation to situation.
In the Height2Group
model, Height
model, the
Coding
In the regression model, Height
. This is the definition of the slope of a line: the amount of “rise” for each one unit of “run”, i.e., how much
In both models, the Height2Group
model, when Height2Group
. In the Height
model, if Height
, but the model can still make a prediction for such a nonsensical student.
Connection to Algebra
In algebra, a straight line is often represented by the equation
In statistics, we use that same linear equation, but we switch it around so the intercept comes first (
Fitting a regression model is a matter of finding the particular line (i.e., slope and intercept) that best fits the data (i.e., that minimizes the sum of squared errors).