Get startedGet started for free

Tableau: forecasting

1. Tableau: forecasting

Creating forecasts in Tableau is similar to the drag and drop analytics you've see before. For this demo, we're going to look whether we can predict the number of YouTube views Mariah Carey gets each year in December for her song "All I Want for Christmas". We can visualize the number of new views as a line chart, aggregated per month. It seems that the data prior to April 2017 is wrong, and that the data from February 2021 is incomplete, so let's filter those months out. In the Analytics pane, you see the Forecast option. Drag and drop it to the canvas. A light blue line is added with the estimated forecasts, including a 95 percent confidence interval by default. Tableau creates a gap between the actual and estimated values, you can avoid this by changing the forecast indicator to an attribute. The model predicts about 25 million new views in December 2020. How good is this prediction? You can find this information by describing the forecast: right click the canvas, select Forecast, then Describe Forecast. The pop-up window summarizes the time series forecast you created, and mentions the overall quality, which is Good in this case. To further quantify what "Good" means, you can go to the Models section, and check the Quality Metrics. Notice the Mean Absolute Scaled Error, which is very close to zero. The MASE tells you that this model has 11 percent error of the naive forecast, meaning that it is far better than just using the last observation to predict the future. You can always click here to learn more about the forecast descriptions. You can also customize the forecast, under the Forecast Options menu. You can specify how far into the future the forecast extends, but notice that predictions further in the future become less accurate or even impossible. By default, Tableau leaves out the last month to make predictions, but since we already left that month out, we can set it to zero. For more advanced users, Tableau offers the possibility to override the default model by a customized one. Unless you're familiar with exponential smoothing, you can leave these setting to their default values. Lastly, you can change the level of the confidence interval. You can add forecast options and results to the tooltip. Drag the New Views Measure to the Tooltip mark, and notice the upward arrow, indicating that it holds forecast values. Under Forecast result, you can add additional details to the tooltip, including the precision (the lower and upper predicted values), in absolute values or percentages, and the quality of the model, based on the MASE. You can add multiple measures to the Tooltip mark to add additional details. In this case, the prediction quality for December 2020 is 89 percent (100 percent being the best possible quality), and the true new views could be 16 million views higher or lower than the predicted 25 million new views. OK, up to you now!

2. Let's practice!