Book Image

Supervised Machine Learning with Python

By : Taylor Smith
Book Image

Supervised Machine Learning with Python

By: Taylor Smith

Overview of this book

Supervised machine learning is used in a wide range of sectors, such as finance, online advertising, and analytics, to train systems to make pricing predictions, campaign adjustments, customer recommendations, and much more by learning from the data that is used to train it and making decisions on its own. This makes it crucial to know how a machine 'learns' under the hood. This book will guide you through the implementation and nuances of many popular supervised machine learning algorithms, and help you understand how they work. You’ll embark on this journey with a quick overview of supervised learning and see how it differs from unsupervised learning. You’ll then explore parametric models, such as linear and logistic regression, non-parametric methods, such as decision trees, and a variety of clustering techniques that facilitate decision-making and predictions. As you advance, you'll work hands-on with recommender systems, which are widely used by online companies to increase user interaction and enrich shopping potential. Finally, you’ll wrap up with a brief foray into neural networks and transfer learning. By the end of this book, you’ll be equipped with hands-on techniques and will have gained the practical know-how you need to quickly and effectively apply algorithms to solve new problems.
Table of Contents (11 chapters)
Title Page
Copyright and Credits
About Packt

Introduction to non-parametric models and decision trees

In this section, we're going to formally define what non-parametric learning algorithms are, and introduce some of the concepts and math behind our first algorithm, called decision trees.

Non-parametric learning

Non-parametric models do not learn parameters. They do learn characteristics or attributes about the data, but not parameters in the formal sense. We will not end up extracting a vector of coefficients. The easiest example is a decision tree. A decision tree is going to learn where to recursively split data so that its leaves are as pure as possible. So, in that sense, the decision function is a splitting point for each leaf that is not a parameter.

Characteristics of non-parametric learning algorithms

Non-parametric models tend to be a bit more flexible and do not make as many assumptions about the underlying structure of the data. Many linear models, or parametric models, for instance, assume that a normal distribution for each...