Types of Machine Learning Models Explained (2024)

A machine learning model is a program that is used to make predictions for a given data set. A machine learning model is built by a supervised machine learning algorithm and uses computational methods to “learn” information directly from data without relying on a predetermined equation. More specifically, the algorithm takes a known set of input data and known responses to the data (output) and trains the machine learning model to generate reasonable predictions for the response to new data.

Table of Contents

  • Types of Machine Learning Models
  • Machine Learning Models with MATLAB
  • Integrate Machine Learning Models into Systems

Tutorials and examples

Types of Machine Learning Models

There are two main types of machine learning models: machine learning classification (where the response belongs to a set of classes) and machine learning regression (where the response is continuous).

Choosing the right machine learning model can seem overwhelming—there are dozens of classification and regression models, and each takes a different approach to learning. This process requires evaluating tradeoffs, such as model speed, accuracy, interpretability, and complexity, and can involve trial and error.

The following is an overview of machine learning classification and regression machine learning models to help you get started.

Types of Machine Learning Models Explained (1)

Machine learning models for classification and regression with MATLAB.

Popular Machine Learning Models for Classification or Regression

Machine Learning Model

How Machine Learning Model Works

Machine Learning Model Representation

Support Vector Machine (SVM)

An SVM classifies data by finding the linear decision boundary (hyperplane) that separates data points of one class from data points of the other class. The best hyperplane for an SVM has the largest margin between the two classes when the data is linearly separable. If the data is not linearly separable, a loss function penalizes points on the wrong side of the hyperplane. SVMs sometimes use a kernel transformation to project nonlinearly separable data into higher dimensions where a linear decision boundary can be found.

SVM regression algorithms work like SVM classification algorithms, but the regression algorithms are modified to predict continuous responses. They find a model that deviates from the measured data with minimal parameter values to reduce sensitivity to errors.

Classification

Types of Machine Learning Models Explained (2)

Regression

Types of Machine Learning Models Explained (3)

Decision Tree

A decision tree lets you predict responses to data by following the decisions in the tree from the root (beginning) down to a leaf node. A tree consists of branching conditions where the value of a predictor is compared to a trained weight. The number of branches and the values of weights are determined in the training process. Additional modification, or pruning, may be used to simplify the model.

Types of Machine Learning Models Explained (4)

Ensemble Trees

In ensemble methods, several weaker decision trees are combined into a stronger ensemble. A bagged decision tree consists of trees that are trained independently on bootstrap samples of the input data.

Boosting involves iteratively adding and adjusting the weight of weak learners. There is an emphasis on misclassified observations or fitting new learners to minimize the mean-squared error between the observed response and the aggregated prediction of all previously grown learners.

Types of Machine Learning Models Explained (5)

Generalized Additive Model (GAM)

GAM models explain class scores or response variables using a sum of univariate and bivariate shape functions of predictors. These models use a shape function, such as a boosted tree, for each predictor and, optionally, each pair of predictors. The shape function can capture a nonlinear relation between predictors and predictions.

Types of Machine Learning Models Explained (6)

Neural Network

Inspired by the human brain, a neural network consists of interconnected nodes or neurons in a layered structured that relate the inputs to the desired outputs. The machine learning model is trained by iteratively modifying the strengths of the connections so that given inputs map to the correct response.

The neurons between the input and output layers of a neural network are referred to as hidden layers. Shallow neural networks typically have few hidden layers. Deep neural networks have more hidden layers than shallow neural networks. They can have hundreds of hidden layers.

Neural networks can be configured to solve classification or regression problems by placing a classification or regression output layer at the end of the network. For deep learning tasks, such asimage recognition, you can usepretrained deep learning models. Common types of deep neural network are CNNs and RNNs.

Types of Machine Learning Models Explained (7)

Popular Machine Learning Models for Classification

Machine Learning Model

How Machine Learning Model Works

Machine Learning Model Representation

Naive Bayes

A naive Bayes classifier assumes that the presence of a feature in a class is independent of other features. It classifies new data based on the highest probability of it belonging to a particular class. This probability is determined by the probabilities of each feature.

Types of Machine Learning Models Explained (8)

k-Nearest Neighbor (KNN)

KNN is a type of machine learning model that categorizes objects based on the classes of their nearest neighbors in the data set. KNN predictions assume that objects near each other are similar. Distance metrics, such as Euclidean, city block, cosine, and Chebyshev, are used to find the nearest neighbor.

Types of Machine Learning Models Explained (9)

Discriminant Analysis

Discriminant analysis classifies data by finding linear combinations of features. The analysis assumes that different classes generate data based on Gaussian distributions. Training the machine learning model involves finding the parameters of a Gaussian distribution for each class. Boundaries, either linear or quadratic, are calculated based on these parameters. These boundaries are used to classify new data.

Types of Machine Learning Models Explained (10)

Popular Machine Learning Models for Regression

Machine Learning Model

How Machine Learning Model Works

Machine Learning Model Representation

Linear Regression

Linear regression is a statistical modeling technique used to describe a continuous response variable as a linear function of one or more predictor variables. Because linear regression models are simple to interpret and easy to train, they are often the first models to try when working with a new data set.

Types of Machine Learning Models Explained (11)

Nonlinear Regression

Nonlinear regression is a statistical modeling technique that helps describe nonlinear relationships in experimental data. These models are generally assumed to be parametric, described as nonlinear equations.

Nonlinear refers to a fit function that is a nonlinear function of the parameters. For example, if the fitting parameters are b0, b1, and b2: the equation y = b0+b1x+b2x2is a linear function of the fitting parameters, whereas y = (b0xb1)/(x+b2) is a nonlinear function of the fitting parameters.

Types of Machine Learning Models Explained (12)

Generalized Linear Model

A generalized linear model (GLM) is a special case of nonlinear models that uses linear methods. The inputs are transformed by a nonlinear link function such as a logarithm or logit function. The linear combination of transformed inputs is solved using a linear best fit. The logistic regression machine learning model is an example of a GLM.

Types of Machine Learning Models Explained (13)

Gaussian Process Regression (GPR)

GPR models are nonparametric machine learning models used for predicting the value of a continuous response variable. The response variable is modeled as a random Gaussian process, using covariances with each input variable. The machine learning model also models the uncertainty of the response.

These models are widely used in spatial analysis for interpolation in the presence of uncertainty. GPR is also referred to as Kriging.

Types of Machine Learning Models Explained (14)

Machine Learning Models with MATLAB

Using MATLAB® with Statistics and Machine Learning Toolbox™, you can train many types of machine learning models for classification and regression. The following tables list MATLAB functions that create popular machine learning models and documentation topics, which describe how the machine learning models work. With MATLAB, you can create more machine learning models than the ones listed here.

Machine Learning Models for Classification

Machine Learning Model

MATLAB Function that Creates Machine Learning Model

How Machine Learning Model Works in MATLAB

SVM

fitcsvm

Naive Bayes

fitcnb

KNN

fitcknn

Decision Tree

fitctree

Decision Tree Ensemble

fitcensemble

Discriminant Analysis

fitcdiscr

GAM

fitcgam

Shallow Neural Network

fitcnet

Deep Neural Network

trainNetwork

Machine Learning Models for Regression


Machine Learning Model

MATLAB Function that Creates Machine Learning Model

How Machine Learning Model Works in MATLAB

Linear Regression

fitlm

Nonlinear Regression

fitnlm

GPR

fitrgp

SVM

fitrsvm

Generalized Linear Model

fitglm

Tree

fitrtree

Regression Tree Ensemble

fitrensemble

GAM

fitrgam

Shallow Neural Network

fitrnet

Deep Neural Network

trainNetwork

MATLAB provides low-code apps (Classification Learner and Regression Learner) for designing, tuning, assessing, and optimizing machine learning models.

Classification Learner App

Types of Machine Learning Models Explained (15)

Regression Learner App

Types of Machine Learning Models Explained (16)

Specialized apps for interactively exploring data, selecting features, and training, comparing, and assessing machine learning models.

With MATLAB, you can automate the process of building optimized machine learning models. Using autoML techniques, you can streamline data exploration and preprocessing, feature extraction and selection, machine learning model selection and tuning, and the preparation of a machine learning model for deployment.

Classify Data Using the Classification Learner App (4:34)

Forecast Electrical Load Using the Regression Learner App (3:42)

Integrate Machine Learning Models into System

Using MATLAB and Simulink® with Statistics and Machine Learning Toolbox, you can integrate machine learning models into the design and simulation of complex AI-driven systems, such as a reduced-order model of a vehicle engine.

Types of Machine Learning Models Explained (17)

Integrate a machine learning model into a Simulink system by using a dedicated block.

For each machine learning model, a dedicated Simulink block exists. The following table lists Simulink blocks and relevant examples for integrating classification and regression machine learning models into system designs.

Simulink Blocks for Classification Models

Machine Learning Model

Simulink Block for Machine Learning Model

How To Integrate Machine Learning Model in Simulink System

SVM

ClassificationSVM Predict

KNN

ClassificationKNN Predict

Decision Tree

ClassificationTree Predict

Decision Tree Ensemble

ClassificationEnsemble Predict

Shallow Neural Network

ClassificationNeuralNetwork Predict

Deep Neural Network

Predict

Simulink Blocks for Regression Models

Machine Learning Model

Simulink Block for Machine Learning Model

How To Integrate Machine Learning Model in Simulink System

Linear Regression

RegressionLinear Predict

GPR

RegressionGP Predict

SVM

RegressionSVM Predict

Regression Tree

RegressionTree Predict

Regression Tree Ensemble

RegressionEnsemble Predict

Shallow Neural Network

RegressionNeuralNetwork Predict

Deep Neural Network

Predict

Learn More About Machine Learning Models

Introduction to Machine Learning 4 videos

Introduction to Machine Learning (4 videos)

Machine Learning with MATLAB

Integrating AI into System-Level Design

Related Topics

Machine Learning

Artificial Intelligence

Deep Learning

Getting Started with MATLAB

Types of Machine Learning Models Explained (23)

MATLAB for Machine Learning

Learn about MATLAB support for machine learning.

Types of Machine Learning Models Explained (24)

Tutorials and Examples

Get started with MATLAB for machine learning.

Types of Machine Learning Models Explained (25)

Select a Web Site

Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .

You can also select a web site from the following list

Americas

  • América Latina (Español)
  • Canada (English)
  • United States (English)

Europe

  • Belgium (English)
  • Denmark (English)
  • Deutschland (Deutsch)
  • España (Español)
  • Finland (English)
  • France (Français)
  • Ireland (English)
  • Italia (Italiano)
  • Luxembourg (English)
  • Netherlands (English)
  • Norway (English)
  • Österreich (Deutsch)
  • Portugal (English)
  • Sweden (English)
  • Switzerland
    • Deutsch
    • English
    • Français
  • United Kingdom(English)

Asia Pacific

  • Australia (English)
  • India (English)
  • New Zealand (English)
  • 中国
  • 日本Japanese (日本語)
  • 한국Korean (한국어)

Contact your local office

Types of Machine Learning Models Explained (2024)
Top Articles
5 habits to borrow from people who've lived to 100
Grief Recovery Center
Northern Counties Soccer Association Nj
Cold Air Intake - High-flow, Roto-mold Tube - TOYOTA TACOMA V6-4.0
Windcrest Little League Baseball
Fredatmcd.read.inkling.com
Collision Masters Fairbanks
Professor Qwertyson
35105N Sap 5 50 W Nit
The Powers Below Drop Rate
Vocabulario A Level 2 Pp 36 40 Answers Key
414-290-5379
Full Range 10 Bar Selection Box
Sams Gas Price Fairview Heights Il
Detroit Lions 50 50
Hillside Funeral Home Washington Nc Obituaries
Everything You Need to Know About Holly by Stephen King
Theycallmemissblue
Craigslist Motorcycles Orange County Ca
Restaurants Near Paramount Theater Cedar Rapids
Cashtapp Atm Near Me
Ou Class Nav
2 Corinthians 6 Nlt
Aldi Süd Prospekt ᐅ Aktuelle Angebote online blättern
Aris Rachevsky Harvard
Our History
Craigslist Apartments Baltimore
Litter Robot 3 RED SOLID LIGHT
2487872771
Craigslist Lake Charles
Amerisourcebergen Thoughtspot 2023
SOGo Groupware - Rechenzentrum Universität Osnabrück
WRMJ.COM
Hobby Lobby Hours Parkersburg Wv
Mini-Mental State Examination (MMSE) – Strokengine
ATM, 3813 N Woodlawn Blvd, Wichita, KS 67220, US - MapQuest
About | Swan Medical Group
Dumb Money, la recensione: Paul Dano e quel film biografico sul caso GameStop
Amici Pizza Los Alamitos
Best Restaurants In Blacksburg
Delaware judge sets Twitter, Elon Musk trial for October
Merkantilismus – Staatslexikon
“To be able to” and “to be allowed to” – Ersatzformen von “can” | sofatutor.com
How to Get a Better Signal on Your iPhone or Android Smartphone
Author's Purpose And Viewpoint In The Dark Game Part 3
Hillsborough County Florida Recorder Of Deeds
The Blackening Showtimes Near Ncg Cinema - Grand Blanc Trillium
Syrie Funeral Home Obituary
Race Deepwoken
Quest Diagnostics Mt Morris Appointment
Latest Posts
Article information

Author: Lilliana Bartoletti

Last Updated:

Views: 5955

Rating: 4.2 / 5 (53 voted)

Reviews: 92% of readers found this page helpful

Author information

Name: Lilliana Bartoletti

Birthday: 1999-11-18

Address: 58866 Tricia Spurs, North Melvinberg, HI 91346-3774

Phone: +50616620367928

Job: Real-Estate Liaison

Hobby: Graffiti, Astronomy, Handball, Magic, Origami, Fashion, Foreign language learning

Introduction: My name is Lilliana Bartoletti, I am a adventurous, pleasant, shiny, beautiful, handsome, zealous, tasty person who loves writing and wants to share my knowledge and understanding with you.