# Starting simple – observational data and linear regression

In previous chapters, we discussed the concept of association. In this section, we’ll quantify associations between variables using a regression model. We’ll see the geometrical interpretation of this model and demonstrate that regression can be performed in an arbitrary direction. For the sake of simplicity, we’ll focus our attention on linear cases. Let’s start!

## Linear regression

**Linear regression** is a basic data-fitting algorithm that can be used to predict the expected value of a dependent (target) variable, , given values of some predictor(s), . Formally, this is written as .

In the preceding formula, is the predicted value of given that takes the value(s) . is the **expected value** operator. Note that can be multidimensional. In such cases, is usually represented as a matrix, **X**, with shape , where is the number of observations and is the dimensionality of (the number of...