CHAPTER 6Supervised Learning—Linear Regression
Types of Linear Regression
In the previous chapter, you learned how to get started with machine learning using simple linear regression, first using Python, and then followed by using the Scikit‐learn library. In this chapter, we will look into linear regression in more detail and discuss another variant of linear regression known as polynomial regression.
To recap, Figure 6.1 shows the Iris dataset used in Chapter 5, “Getting Started with Scikit‐learn for Machine Learning.” The first four columns are known as the features, or also commonly referred to as the independent variables. The last column is known as the label, or commonly called the dependent variable (or dependent variables if there is more than one label).
In simple linear regression, we talked about the linear relationship between one independent variable and one dependent variable. In this chapter, besides simple linear regression, we will also discuss the following:
- Multiple Regression Linear relationships between two or more independent variables and one dependent variable.
- Polynomial Regression Modeling the relationship between one independent variable and one dependent variable using an nth degree ...
Get Python Machine Learning now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.