MACHINE LEARNING • LESSON 2

Prediction Problems

A prediction problem asks a Machine Learning model to estimate an unknown outcome using information that is already available.

THE CORE IDEA

We know some information, but we don't know the answer yet.

The model learns from previous examples where the outcome was known and then uses what it learned to estimate the outcome for new data.

01

What Does "Prediction" Mean?

Prediction does not necessarily mean predicting something in the future.

In Machine Learning, prediction can simply mean estimating an unknown value or outcome from known information.

FUTURE Tomorrow's temperature

We use available information to estimate a future value.

UNKNOWN VALUE House price

The house exists, but we may not know its current market value.

02

The Basic Prediction Structure

KNOWN INFORMATION Input

Information available to the model.

LEARNED MODEL Model

Uses patterns learned from previous examples.

UNKNOWN Prediction

The outcome we want to estimate.

03

Example: House Price Prediction

Suppose we want to estimate the price of a house.

KNOWN House size

1,500 square feet.

KNOWN Location

A particular neighborhood.

UNKNOWN Price

The value we want to estimate.

The model can use the available information and produce an estimated house price.

04

The Model Learns From Previous Examples

The model does not know the answer automatically. We first provide examples where both the input and the actual outcome are known.

EXAMPLE 1 1,000 sq ft → $300,000
EXAMPLE 2 1,500 sq ft → $420,000
EXAMPLE 3 2,000 sq ft → $550,000
These are training examples.

The model uses examples like these to learn a relationship between the available information and the known outcome.

05

Then We Give It a New Example

After training, we can provide information about a new house where the price is not yet known.

NEW HOUSE 1,700 sq ft

The size is known.

TRAINED MODEL Estimate

Uses what it learned from previous examples.

PREDICTION $470,000

Example estimated price.

06

Prediction Is an Estimate

A prediction should not be treated as a guaranteed answer.

MODEL PREDICTION $470,000

What the model estimated.

ACTUAL VALUE $490,000

What the house actually sold for.

A difference does not automatically mean the model is useless.

We need appropriate evaluation methods to measure how accurate or useful the model is.

07

Prediction Can Mean Different Things

The output being predicted depends on the problem.

NUMBER $470,000

Predict a numerical value such as price.

CATEGORY Spam

Predict which category an example belongs to.

PROBABILITY 82%

Estimate the likelihood of an outcome.

08

Prediction Problems Are Everywhere

E-COMMERCE Predict product demand

Estimate how many units customers may buy.

FINANCE Predict risk

Estimate the likelihood of a particular financial outcome.

HEALTHCARE Predict patient risk

Estimate the likelihood of an outcome using available patient information.

WEATHER Predict temperature

Estimate a future temperature using relevant historical information.

09

What Makes Something a Prediction Problem?

1. We have information about the example.

The model receives input data.

2. There is an outcome we care about.

We clearly define what we want the model to produce.

3. We have examples from which the model can learn.

Historical examples connect inputs with known outcomes.

KEY IDEA

Prediction = Estimate an Unknown Outcome From Known Information

A Machine Learning model learns from previous examples and uses the learned relationship to estimate an outcome for new input.

QUICK CHECK

Which Part Is Unknown?

House price

We may know the house characteristics, but the price we want to estimate is unknown.

Customer purchase

We may know the customer's behavior, but whether they will purchase is unknown.

Tomorrow's temperature

We know historical and current information, but tomorrow's temperature is unknown.

NEXT TOPIC

Classification Problems

Prediction does not always mean predicting a number. Next, we'll look at problems where the output is a category, such as Spam or Not Spam.