Forecasting in Power BI

Time Series Analysis in Power BI

Kevin Barlow

Data Analytics Professional

Context and importance

Prediction is a more sophisticated analytic technique, allowing us to try and gain knowledge about what will happen, not just what has happened.

Forecasting Example

Time Series Analysis in Power BI

Forecasting types

Forecasting

  • Takes existing data and projects into future dates
  • A kind of predictive or prescriptive analytics

Industry Examples

  1. Forecasting demand for a particular product
  2. Predicting the headcount needed to support your engineering department

Hindcasting

  • Take your forecast and "predicts" your existing data
  • Typically used to test the accuracy of forecast model

Industry Examples

  1. Hindcasting climate conditions that led to particular environmental changes
  2. Seeing if the stock forecast model is accurate
Time Series Analysis in Power BI

Forecasting fundamentals

Forecasting takes historical data and attempts to predict values for future dates.

Take a look at the following table:

date value
January 1 5
January 2 10
January 3 15
January 4
January 5

By using the overall trend of our data, we can relatively reliably predict what we think the next values should be. This is an example of a linear regression.

date value
January 1 5
January 2 10
January 3 15
January 4 20
January 5 25
Time Series Analysis in Power BI

Forecasting messy data

Time series data is often messy and can be problematic to forecast unless "cleaned" up.

Exponential Smoothing is a technique to "smooth out" the noise in data.

Exponential Smoothing GIF

Time Series Analysis in Power BI

Confidence in forecasts

With any forecast, there is going to be an error because we don't have actual data for those dates!

Confidence Intervals - provide a range of estimates that the data will fall into with an assumed level of confidence (%)

Power BI allows you to configure how much confidence you want in forecasts.`

Confidence Intervals GIF

Time Series Analysis in Power BI

Stock dataset

We will practice forecasting on some stock data for Microsoft (ticker: MSFT). The data includes basic information on the stock's trading price on a given day.

MSFT Stock Data Screenshot

Time Series Analysis in Power BI

Let's practice!

Time Series Analysis in Power BI

Preparing Video For Download...