True Negative, Explained

An image that shows True Negatives in the context of the classification threshold, True Positives, False Positives, and False Negatives.

If you want to master building classification systems for machine learning, you need to understand how to evaluate classifiers. And in turn, that means you need to understand classification metrics. In classification there are a wide variety of metrics, like precision, recall, sensitivity, accuracy, and many others, but most of these metrics are actually based … Read more

True Positive, Explained

An image that shows True Positives among other classified examples that include TN, FP, and FN.

When you begin immersing yourself in the world of classification systems, you’ll encounter a large number of different classification metrics: precision; recall; accuracy; sensitivity and specificity; F1-score; and many more. But as you begin digging into these metrics you’ll find another quantity that underpins them all: true positives. To understand classification generally as well as … Read more

The ROC Curve, Explained

An image that shows an ROC curve, with the title "ROC Curves, Explained."

In machine learning, evaluating the performance of a model is as important as its creation. We need tools and techniques to help guarantee that the model performs well and meets the standards of our task. Enter the ROC curve – a powerful visualization designed for evaluating the performance of a machine learning classification system. This … Read more

Confusion Matrix, Explained

A Confusion Matrix, Explained, which shows a 2x2 grid of correct and incorrect classification predictions.

The confusion matrix is an important and commonly used tool in machine learning. This is particularly true of classification problems, where we build systems that predict categorical values. Because they’re used so frequently for classification problems, you need to know them, and you need to know them well. So in this blog post, I’m going … Read more

How to Use the Sklearn Logistic Regression Function

An image of a logistic regression model made with Scikit-learn, also showing a piece of Scikit-learn code.

In this tutorial, I’ll show you how to use the Sklearn Logistic Regression function to create logistic regression models in Python. I’ll quickly review what logistic regression is, explain the syntax of Sklearn LogisticRegression, and I’ll show you a step-by-step example of how to use the technique. If you need something specific, just click on … Read more

Sklearn make_classification, Explained

An image of code that uses Scikit-learn make_classification to create a binary classification dataset, and an image of a scatterplot that plots the resulting binary data.

With the rise of AI, machine learning has suddenly become very popular. Machine learning has been around for decades, but machine learning systems are becoming increasingly important in a range of fields, from healthcare, to finance, to marketing. Python, with a range of libraries for data science and ML, has arguably become the top language … Read more

How to Make a Python Perceptron from Scratch

An image that shows a Perceptron, and code to initialize a Python Perceptron.

The Perceptron stands as one of the most basic building blocks for creating neural networks, including more advanced structures like deep networks and their variants. Originally developed in the late 1950s, Perceptrons were designed to mimic the function of biological neurons. I recently wrote a blog post explaining some of the history of Perceptrons as … Read more