

# Manage demand plans


After the forecast is generated, choose **Demand Planning**, and then choose **Manage Demand Plan**. On the **Demand Planning** page, you can view the overall influence factors used in generating the forecast and the accuracy metrics of the forecast. You can also view the current demand plan.

**Topics**
+ [

# Overview
](overview_dp.md)
+ [

# Demand plan
](changing_category.md)
+ [

# Forecast lock
](forecast_lock.md)

# Overview


**Note**  
You can only view the **Overview** page after the forecast is generated for the first time.

The **Overview** tab provides the following information.
+ **Overall Influence Factors** – Indicates the impact score of product metadata attributes and demand drivers (if any), used to generate forecast in the current planning cycle. You can view the influence factors after the first successful forecast generation. A negative value indicates the attributes caused the forecast to go down and vice versa. A zero value indicates that the attribute has no influence on the forecast result. For information on forecast based on demand drivers, see [Forecast based on demand drivers](demand_drivers.md).
+ **Accuracy Metrics** – After you update the dataset (outbound\$1order\$1line) that contains the actual demand for the forecast period, choose **Recalculate**. You can view the accuracy metrics for the latest demand plan under the **Demand Plan** tab. Accuracy metrics measure how the accuracy of the current demand plan aligns with the actual demand.

  Accuracy metrics are available at **plan (aggregate)** and **granular lowest** level during forecast generation. The **Overview** page displays the aggregate level metrics and under **Accuracy Metrics**, you can choose **Download ** to download the granular metrics.

  The following are the formulas used to calculate the metrics displayed on the web application.
  + ** Mean Absolute Percentage Error (MAPE)** – MAPE takes the absolute value of the percentage error between observed and predicted values for each unit of time and averages those values.

    The formula at granular and plan level is below:   
![\[Calculating MAPE\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/MAPE_formula.png)

    A MAPE less than 5% indicates the forecast is acceptably accurate. A MAPE greater than 10% but less than 25% indicates low, but acceptable accuracy, and MAPE greater than 25% indicates very low accuracy and the forecast is not acceptable.
  + **Weighted Average Percentage Error (WAPE)** – WAPE measures the overall deviation of forecasted values from observed values. WAPE is calculated by taking the sum of observed values and the sum of predicted values, and calculating the error between those two values. A lower value indicates a more accurate model.

    The formula at granular and plan level is below:   
![\[Calculating WAPE\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/WAPE_formula.png)

    A WAPE less than 5% is considered as acceptably accurate. A WAPE greater than 10% but less than 25% indicates low, but acceptable accuracy and WAPE greater than 25% indicates very low accuracy.

See the following example: 

![\[WAPE calculation example\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/Accuracy_metrics.png)


The metrics are not calculated when actual is zero or null. When a new forecast is generated subsequently, the previous reported metrics will no longer be available on the web application. Make sure the latest outbound\$1order\$1line dataset is updated and choose **Recalculate** to view the updated metrics. 

The accuracy metrics reflect the accuracy of the current demand plan for all time periods that have an actual demand value in the current executed forecast.

For example, if your current planning cycle has forecast from January to December 2023 with monthly forecasts and you updated the actual data for January 2023, accuracy metrics will be computed for January 2023. Similarly, if your current planning cycle has forecast from January to December 2023 with monthly forecasts and you updated the actual data for January 2023 and February 2023, accuracy metrics will be computed for January 2023 and February 2023. The Demand Planning web application will display the aggregated metric for Jan-Feb-2023 and the export file will display the granular details.

**Note**  
When you modify the *Time interval* or *Hierarchy* configuration and regenerate the forecast, the accuracy metrics will not be displayed since the accuracy metric values are not relevant.

## Demand pattern


You can expand the individual metrics to view the demand characteristics such as *Smooth Demand*, *Intermittent Demand*, *Erratic Demand*, and *Lumpy Demand*. The segments are derived based on the actual demand used in the last forecast.

When one or more of the four segments are missing in the Demand Planning web application, it indicates that the Demand Planning web application could not find any product aligned with the patterns associated with the missing segments.

The following intermediate results are calculated:

**Note**  
Records with zero demand are not considered for ADI and CV² computation.
+ *Average Demand Interval (ADI)* – Represents the average time between consecutive demands. ADI = total number of periods / number of demand buckets
+ *Squared Coefficient of Variation (CV²)* – Measures the variability in demand quantities. CV² = (standard deviation of a population / average value of the population)²

The following cut-offs are applied to derive the segments:
+ *Smooth Demand* (ADI less then 1.32 and CV² less than 0.49) is highly regular in time and quantity, making it easy to forecast with low error margins.
+ *Intermittent Demand* (ADI greater than or equal to 1.32 and CV² lesser than 0.49) exhibits little variation in quantity but high variation in demand interval, leading to higher forecast error margins.
+ *Erratic Demand * (ADI less then 1.32 and CV² greater than or equal to 0.49) has regular occurrence in time but high variations in quantity, resulting in shaky forecast accuracy.
+ *Lumpy Demand* (ADI greater than or equal to 1.32 and CV² greater than or equal to 0.49) is characterized by large variations in both quantity and time, making it unforecastable.

## Forecast validation


By default, forecast validation is enabled. To make sure the forecast generated is accurate, Demand Planning will monitor and update you on the forecast quality or accuracy. If Demand Planning determines the forecast requires additional validation, Demand Planning will delay publishing the forecast and you will see a message that displays the date and time when the forecast will be published on the AWS Supply Chain web application.

You can also opt-out and Demand Planning will not monitor your forecast. For more information on how to opt-out, see [Opt-out preference](https://docs.aws.amazon.com/aws-supply-chain/latest/adminguide/data-protection.html#opt-out-preference).

You can view the last published demand plan in read-only mode.

## Lags


Lags represent the time interval between when the forecast was created and the actual forecast was realized. You can configure up to three forecast lags when you configure demand plan. For more information, see [Create your first demand plan](onboarding.md). The forecast accuracy metrics displays the analysis based on the lag intervals defined.

Forecasts for the defined lags are generated for every planning cycle and the accuracy metrics can only be evaluated after the corresponding number of planning cycles. For example, if you choose lag six, accuracy metrics for lag six forecast will be calculated after six planning cycles.

![\[Demand pattern example\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/demand_pattern.png)


**Note**  
When you change the lag configuration, the drop-down values displayed are the newly selected lags. Choose **Refresh Metrics** to view the latest metrics. When you change the time interval (daily/weekly/monthly/yearly), or hierarchy (product/site/customer/channel) granularity, the previous lag metrics will no longer be available when you choose **Refresh Metrics**. The recalculation results will display the latest demand planning cycle as the only cycle in history.

Choose **Export Metrics** to download a detailed file that includes granular data corresponding to the aggregated metrics displayed on the web application. The downloaded file will contain the following information:
+ Timestamp - Forecasted Period, Forecast Creation Date, Last Actual Period, Lag
+ XYZ segment (smooth, intermittent, erratic or lumpy)
+ Granularity - Product/site/customer/channel as configured
+ Baseline forecasts - P10, P50 and P90
+ Actual demand
+ Metrics - Bias Units, Bias %, MAPE, SMAPE (at granular level, MAPE and WAPE are the same)

# Demand plan


After the forecast is generated, you can review the forecast values on the **Demand Plan** tab. The **Enterprise demand plan** is a single workbook that serves as a collaborative platform to work together. It provides a centralized location for you to consolidate and synchronize the forecasting effort.

The Demand Plan table displays the following information:
+ **Forecasted Demand** – Displays the system generated forecast and includes the following three values:
  + **Lower Bound** – Forecast prediction that is typically higher than the actual demand around 90 percent of the time.
  + **Median Demand** – Forecast prediction that is typically higher than the actual demand 50 percent of the time (central estimate).
  + **Upper Bound** – Forecast prediction that is typically higher than the actual demand 10 percent of the time.
**Note**  
*Lower and Upper Bound * information is only displayed when a *product\$1id* is selected. *Median Demand* is displayed at both aggregate level and when a single *product id* is selected.
+ **Demand Plan** – Median Demand is replicated in this row to allow for overrides.
+ **Actual Demand** – Displays demand history for the current and prior years.

  When comparing historical data on a weekly basis, Demand Planning will reference the closest Monday in the previous year. This is because Demand Planning considers Monday as the starting day of the week. Due to variations between years and leap years, the corresponding week in the previous year might not have the exact same date. For example, to compare if historical sales data for the week of 6/3/2023 is available, which is a Monday, Demand Planning will reference the week with the closest Monday in the previous year, which is 7/2/2022. 
+ **Prior Forecast Versions** – The last published demand plan displays. This will be blank during the first forecast creation because no history is available.
+ **Lifecycle and Events** – Displays the products in the demand plan that are New Product Introductions (NPI) or products that are nearing End of Life (EoL). When you hover over the **NPI** or **EoL** icons, when more than one product is selected, you can view the number of products and the list of products. When only one product is selected, you can view the product metadata. , product available day in case of NPI, discontinue day in case of EoL, and forecast start and stop date.
**Note**  
You will only see the number of products that are new or nearing EoL listed when the product category is set to all or when a higher level in product hierarchy is selected.

You can use the **Graph** toggle button to hide or show the graph view. You can hide or show the specific value by choosing the eye icon. When you filter by products, you can hover over the *i* help icon to view the product description, unit of measure (UoM), product available date, and discontinue date.

## Viewing the forecast


To view the forecast, complete the following steps:

1. On the **Enterprise demand plan** page, you can see the timestamp of the forecast generated. If the **Enterprise demand plan** is in *active* state, you can use the filters and make adjustments.

1. On the **Enterprise demand plan** page, under **All**, choose **Change category/product** to change the generated forecast view. By default, the forecast displayed represents the total forecast demand for all products within the defined scope or time horizon.

1. On the **Select Category/Product** page, you can select the product from the list or use the search box to search for a particular product by *Product ID* or *Description*.

1. Choose **Apply**. You can now view the filtered forecast for the selected product or category.
**Note**  
If you had chosen optional hierarchies during forecast configuration, the summary box will display the count of site, customer, and channel the selected product is sold.

1. Under **Refine your search**, if you chose optional hierarchies during forecast configuration, you can filter for **Site**, **Channel**, or **Customer** to further refine your forecast. For example, if you chose **Site** and **Channel** hierarchy during forecast configuration, the filters for Site and Channel will be available on the **Demand Plan** page.

1. In the **Time interval** dropdown list, select the time interval to view the forecast. You can use this filter to adjust the time hierarchy and view the forecast in both table and graph form. The lowest value corresponds to the forecast granularity time interval setting. For example, if the time interval is *Weekly*, you can view the forecast at *Weekly*, *Monthly* and *Yearly*. 

   You can also use the **Viewing window start** and **Viewing window end** to narrow down the period that you want to view in the forecast, both in table and graph view. You can view the historical sales for 28 days, 52 weeks, 48 months, and 10 years.

**Time interval example 1**

Demand Plan is generated at daily time-intervals per configuration. You can view the Demand Plan at weekly time interval by selecting the option on the Time Interval filter on the Demand Plan page. The system will aggregate values into weeks with Monday as the starting day of the week.

You can also view the demand plan in monthly time interval by using the Time Interval filter and selecting the monthly option. System will aggregate values into Gregorian calendar month with start day as 1, because demand plan is available at daily granularity.

![\[Time interval example\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/Time-interval-example1.png)


**Time interval example 2**

Demand plan is generated at weekly time-interval per configuration. You can view the Demand plan at monthly time interval by selecting the Time Interval filter. The time boundaries for month will not be strict Gregorian calendar month.

![\[Time interval example\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/Time_interval_example.png)


## Adding an override


This section describes how to manually edit the forecast to override the projected demand.

**Note**  
Manual forecast overrides from one planning cycle are automatically saved and reapplied on the next planning cycle. 

1. Under **Demand Plan**, you can add overrides on the graph by moving the dot to the desired value or update the values directly on the Demand Plan row in the table.

1. On the **Edit Quantity** page, under **Change**, select if you want to increase, decrease, or fixed amount the demand.

1. Choose **Bulk edit** to bulk edit the forecast and add an override.

   The **Edit your forecast** page appears.

1. Under **Change**, select the dropdown to increase or decrease the demand, or enter a value.

1. Under **Reason Code**, select from one of the options between *Promotion*, *Holiday*, *Seasonal*, *New Product*, *Product Rampdown* or *Others*. The reason code is mandatory to successfully process the override. It is optional to add more descriptive notes to a forecast override.

1. Choose **Save and Update**.

   When you create an override, the impact can be viewed throughout the relevant levels of hierarchies. You can create many overrides but only the last override will be considered. After an override is created, a *clock* icon appears under **Demand Plan**. When you choose the *clock* icon, you can view the most recent change in the planning cycle. Choose **View more changes** to view past updates.

1. To make multiple overrides at the same time, from the **Edit Quantity**, choose **Go to bulk editing**. You can also choose **Bulk Edit** against **Demand Plan**.
**Note**  
You can bulk edit only from the table.

1. On the **Edit your forecast** page, you can select all check boxes or a check box for each time period that you want to update, and then enter the updates.

1. Choose **Save and Update**.

   The **Forecasted Demand** is updated.

## Exporting data plan files


You can export **Demand Plan**, **Forecast Demand**, **Prior Forecast Versions**, and **Actual Demand History** from Demand Planning as individual .csv files.

**Note**  
The exported .csv file will contain the entire demand plan, despite which filters were active on the **Demand Planning **page at the time of export.

To export the data plan, complete the following steps:

1. On the **Enterprise demand plan** page, select the vertical ellipsis.

1. Choose **Export Data Plan**.  
![\[Exporting data plans\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/export_data_plan.png)

1. On the **Export** page, select the required data you would like to download.

1. Choose **Export**.

   The file is downloaded on your local computer.

## Importing forecast overrides


You can use the import forecast overrides option to import the forecast overrides using a .csv file.

To upload the forecast overrides through a .csv file, complete the following steps:

1. On the **Enterprise demand plan** page, select the vertical ellipsis.

1. Choose **Import Forecast Overrides**.

   The **Import Forecast Overrides** page appears.  
![\[Importing forecast overrides\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/import_forecast_overrides.png)

1. Under **Upload files**, choose **Download CSV template** to download the .csv file you need to use to add the override values.

   The .csv file will contain the headers from the dataset you used to generate the forecast. The .csv file can only contain upto 1000 rows and the file size should be within 5 MB.

1. After the .csv file is updated, you can drag and drop the files or choose **select files** to add the file.

1. Choose **Upload overrides**.

   If the upload fails, check the following:
   + Make sure the required fields *override\$1start\$1date*, *override\$1end\$1date*, *value*, and *reason\$1code* are populated.
   + The supported reason codes are *Promotion* *Holiday*, *Seasonal*, *New Product*, *Product Rampdown*, and *Others*.
   + Make sure the *override\$1start\$1date* and *override\$1end\$1date* is the first day of the week or month depending on your configuration.

1. Under **Import Forecast Overrides Status**, you will see the status of all the forecast overrides you uploaded.

   You can filter the forecast override status by **Data Uploaded**, **User ID**, or upload status.

## Demand Plan scheduler


Schedulers in Demand Planning determine when forecasts are generated and demand plans are finalized. Schedulers can be configured to operate automatically at set time intervals (auto schedulers) or triggered manually. Auto-schedulers ensure that the planning process runs smoothly and consistently accordingly to predefined timelines, while manual schedulers gives you the flexibility to initiate forecast refreshes and finalize demand plans.
+ Manual refresh and release – Make sure you choose **Manual** under **Demand Plan Scheduler** when you configure demand planning. To start a forecast refresh, on the **Demand Plan** page, select the three dots on the top-right, and choose **Generate Forecast**.

  Select **Finalize demand plan**, if the demand plan is final and ready to be released to downstream processes.

  Once the demand plan is final, the information is published to the *Forecast* data entity in Data Lake and to Amazon S3. The status on the demand plan page for this plan is changed to *Published*. You can view the Amazon S3 link under *Settings* > *Organization*, *Demand Planning*, *Publish Demand Plans*. You can see the **Generate forecast** button to start the next planning cycle.

  When the **Finalize demand plan** is not selected, Demand Planning will publish the forecast as an interim version to the *Forecast* data entity in Data Lake. The status is changed to *Closed*. You can see the **Generate forecast** button to start the next planning cycle. Demand planning will initiate a new forecast as set in the demand planning configuration page and will use the same start date as the previous plan.
+ Automatic refresh and release – Make sure you choose **Auto** under **Demand Plan Scheduler** when you configure demand planning. For more information, see [Create your first demand plan](onboarding.md).



# Forecast lock


You can use the forecast lock feature to lock specific periods in your forecast to prevent any further edits or adjustments. To configure the forecast lock, enter a number between zero and time horizon -1 in the Demand Plan settings page to lock the first *x* forecast period. The default value is 0, indicating no periods are locked.

The forecast lock is not applied to the initial forecast but will take effect from the second demand planning cycle carrying over the finalized values from the previous demand plan. In the Demand Plan, locked periods are indicated by a *lock* icon. The change history icon will display the reason code *PLAN\$1LOCKED* for audit purpose at the most granular level. Once the forecast period is locked, the lock applies to all products within that timeframe. 

When the forecast granularity is changed, forecast overrides from the prior planning cycles are not carried over to the current planning cycle. The prior forecast and accuracy metrics will also not display any data in the Demand plan and any prior forecast locks are no longer valid. It takes two consecutive forecast executions in the modified granularity to apply a new forecast lock. You can unlock forecast periods by setting the configuration to zero and starting a new forecast.

The example below displays how intra-cycle forecast refresh scheduler works (when it's disabled) with forecast lock in the following settings:
+ Demand plan granularity – Weekly
+ Forecast horizon selected – 5
+ intra-cycle forecast refresh schedule – Disabled
+ Final forecast publish – 7th day of the week
+ Lock period – 2

![\[Displays intra-cycle forecast refresh scheduler works (when it's disabled) with forecast lock\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/intra-cycle_with_forecast_lock.png)


The example below displays how intra-cycle forecast refresh scheduler works (when it's enabled) with forecast lock in the following settings:
+ Demand plan granularity – Weekly
+ Forecast horizon selected – 5
+ intra-cycle forecast refresh schedule – Enabled
+ Final forecast publish – 7th day of the week
+ Interim forecast publish – 3rd day of the week
+ Lock period – 2

![\[Displays intra-cycle forecast refresh scheduler works (when it's enabled) with forecast lock\]](http://docs.aws.amazon.com/aws-supply-chain/latest/userguide/images/forecast_intracycle.png)
