Skip navigation

Demand Forecasting for Shipping and Distribution

The Demand Forecasting for Shipping and Distribution Solution uses historical demand data to forecast demand in future periods across various customers, products and destinations. For instance, a shipping or delivery company wants to predict the quantities of the different products its customers want delivered at different locations at future times. A company can use these forecasts as inputs into an allocation tool that optimises operations, e.g. in the routing of delivery vehicles, or to plan capacity in the longer term.

Summary

This is an Azure Solution to reduce the uncertainty in forecasted shipments for organisations that need to plan based on future quantities. This page explains what the solution does and how to install a copy that you can run and modify in your Azure subscription.

Azure Solutions in the Cortana Intelligence Gallery are composed of advanced analytics tools for data ingestion, data storage, scheduling and advanced analytics components – all of the essential elements for running a demand forecasting solution that can be integrated with your current production systems. This solution combines several Azure services. Azure SQL Server is used for storing forecasts and historical distribution data, Azure Machine Learning (AML) web service for hosting the R forecasting code, Azure Data Factory to orchestrate the entire workflow, and Power BI to provide a visualisation of it.

Use the ‘Deploy’ button on this page to deploy an instance of the solution for the Azure subscription that you specify. This will take you through the steps in your subscription necessary to create and launch the resources that make up this solution so that you can run it. The solution includes multiple Azure services (described below) along with Azure functions that, among other tasks, simulate the data and populate the database with it, so that immediately after deployment you will have a working end-to-end solution.

Description

Note: If you have already deployed this solution, click here to view your deployment.

Estimated daily cost: $4.66

Estimated provisioning time: 15 minutes

The Demand Forecasting for Shipping and Distribution Solution uses historical demand data to forecast demand in future periods across various customers, products and destinations. For instance, a shipping or delivery company wants to predict the quantities of the different products its customers want delivered at different locations at future times. Similarly, a vendor or insurer wants to know the number of products that will be returned due to failures over the course of a year. A company can use these forecasts as inputs into an allocation tool that optimises operations, e.g. in the routing of delivery vehicles, or to plan capacity in the longer term.

Characteristics of all of these forecasting cases are:

  • There are numerous kinds of items with differing volumes that roll up under one or more category levels.
  • There is a history available for each item’s quantity at each time in the past. The items’ volumes vary widely, with possibly a substantial number that have zero volume at times.
  • The history of items shows both trends and seasonality, possibly over multiple time scales. The quantities committed or returned are not strongly price sensitive. In other words, the delivery company cannot strongly influence quantities through short-term changes in prices, although there may be other determinants that affect volume, such as the weather.

Under these conditions we can take advantage of the hierarchy formed among the time series of the different items. By enforcing consistency so that the quantities lower in the hierarchy (e.g. individual product quantities) add up to the quantities above (customer product totals), we improve the accuracy of the overall forecast. The same applies if individual items are grouped into categories, even possibly categories that overlap. For example, one might be interested in forecasting the demand for all products in total, by location, by product category, by customer, etc.

This solution computes forecasts at all aggregation levels in the hierarchy for each specified time period. For simplicity, we will refer to both hierarchical and grouped time series as “hierarchical time series”.

Shipping and distribution forecasting in use

We thank Kotahi for working with us to develop this solution. Kotahi is a supply chain company that plans, sources and delivers shipping containers for New Zealand exports. Read their Customer Story about how they engaged with us at Microsoft and a Microsoft Dynamics 2016 Inner Circle partner, DXC Eclipse, to put this into production. The solution helped them to increase their forecast accuracy and thus improve their ability to choose the right size of container ships, at the right times, and dispatch them to the right ports.

What’s under the hood

The solution uses five types of resources hosted and managed in Azure:

  • Azure SQL Server instance (Azure SQL) for persistent storage
  • Azure Machine Learning (AML) web service for hosting the R forecasting code
  • Azure Blob Storage for intermediate storage of generated forecasts
  • Azure Data Factory (ADF) for orchestrating regular runs of the AML model
  • Power BI dashboard for displaying and drilling down on the forecasts
  • The solution automates the running of periodic forecasts, at a pace configured in ADF (e.g. monthly), whereby it learns a model with the current historical data, and predicts quantities for future periods for all products in the product hierarchy. Each forecast cycle consists of a round-trip from the database, through the model, then back to the database. Each cycle measures forecast accuracy by conventional data holdout techniques. You can configure the number of periods, the product categories and the hierarchy among products. You need to load your current data into the Azure SQL database, and extract forecasts after each run from the same database. The solution exposes the R code model to allow further customisations, and to allow you to simulate historical data and test the solution.

    Using the forecasting solution: Getting started

    See the Technical Solution Guide for a full set of instructions on how to use this solution as an example of what is possible with the Cortana Intelligence Suite. For technical problems or questions about deploying this solution, please post in the issues tab of the repository.

    Solution Dashboard

    Here is an example of a snapshot of the forecasts generated by the solution in the PowerBI dashboard that comes with the solution.

    Power BI Snapshot

    Pricing Info

    Your Azure subscription used for the deployment will incur consumption charges on the services used in this solution, approximately $4.66/day. For more information, please visit the Pricing Calculator.

    Note: If you are no longer using the deployed solution, remember to delete it to stop incurring consumption charges.

    Disclaimer

    ©2017 Microsoft Corporation. All rights reserved. This information is provided “as is” and may change without notice. Microsoft makes no warranties, express or implied, with respect to the information provided here. Third-party data was used to generate the solution. You are responsible for respecting the rights of others, including procuring and complying with relevant licences in order to create similar datasets.

    Related solution architectures

    Demand Forecasting

    Accurately forecasting spikes in demand for products and services can give a company a competitive advantage. This solution focuses on demand forecasting within the energy sector.

    Demand Forecasting and Price Optimisation

    Pricing is recognised as a pivotal determinant of success in many industries and can be one of the most challenging tasks. Companies often struggle with several aspects of the pricing process, including accurately forecasting the financial impact of potential tactics, taking reasonable consideration of core business constraints, and fairly validating the executed pricing decisions. Expanding product offerings adds further computational requirements to making real-time pricing decisions, thereby compounding the difficulty of this already overwhelming task.

    User ActionSimulation Personalized OfferLogic System ResponseQueue User ActionQueue Event Hub Stream Analytics Power BI Machine Learning Cold StartProduct Affinity User Document DB Product Offers Reference Product Views Offer Views Cache Update Logic Azure Services Raw Stream Data 1 2 3 5 4

    Personalised offers

    In today’s highly competitive and connected environment, modern businesses can no longer survive with generic, static online content. Furthermore, marketing strategies using traditional tools are often expensive, hard to implement, and do not produce the desired return on investment. These systems often fail to take full advantage of the data collected to create a more personalised experience for the user.