Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
thierry_brunet
Advisor
Advisor


The goal of this blog is to bypass the restriction of one thousand entities that are supported by SAP Analytics Cloud (SAC) Predictive Planning in a predictive model (please refer the online help in section “Restrictions Using Planning Model as Data Source for Smart Predict”).

Note: It is necessary to adjust the planning model accordingly.

To illustrate the explanations, I have created an example of the sales of one thousand car models for ten countries and months since 2015. The goal is to forecast the sales for the next twelve months per country or group of countries and car models.

This is equivalent to generate 10 * 1 000 = 10 000 entities. It is over the limit for one predictive model.

So, the idea is to use custom properties in the planning model . Let’s see how this works.

In SAC, browse to the planning model, open it, and select the dimension Country and expand it.


Fig 1 – Expand Country dimension


The ten countries are listed here.

To show the possibilities, I will group the countries as shown below:

  1. Group 1: USA

  2. Group 2: CHINA

  3. Group 3: FRANCE, BELGIUM, and SWITZERLAND

  4. Group 4: SPAIN and ITALIA

  5. Group 5: UK, IRELAND, and GERMANY


At the bottom of the right panel, click the Create Property button to create a custom property to the  dimension Country. The Edit Property dialog box appears.


Fig 2: Add a custom property USA for Country


In the ID column, for USA, enter the value of the customer property (Description) as USA.


Fig 3: Set value USA for custom property USA for ID USA and nothing for the other IDs


Repeat this for group 2: CHINA.

For Group 3, create the custom property FRANCE BELGIUM SWITZERLAND to Country.


Fig 4: Custom property FRANCE BELGIUM SWITZERLAND for Country


In the ID column, for FR_BE_CH, enter the value of the customer property (Description) as FRANCE BELGIUM SWITZERLAND.


Fig 5: Set value FRANCE BELGIUM SWITZERLAND for custom property FRANCE BELGIUM SWITZERLAND for IDs FRANCE, BELGIUM and SWITZERLAND and nothing for the other IDs


Repeat this for groups 4 and 5. At the end, the page should look like this:


Fig 6: Ten custom properties set for the ten values of Country


Don’t forget to save your planning model.

Proceeding this way allows to simulate the five groups of countries. Each group has one thousand products.

Now that the planning model is prepared, as a planner, I shall start from the planning story as shown below. Here, I have the sales data for each country and all the products from 2015 to 2020. I want to get the predictive forecasts for the twelve months in 2021. I want to create a private version called Private Forecasts, in which, I have copied the actuals. This private version will receive the predictive forecasts generated by SAP Analytics Cloud Predictive Planning for 2021.


Fig 7: Planning story with historical data


Create a Predictive Scenario with one predictive model configured to forecast sales for group 1: USA. The configuration in the figure below shows that the custom property USA has created a virtual dimension COUNTRY.USA. Combined with the dimension PRODUCTS, there are exactly one thousand entities in this predictive model, and we are still under the limit.


Fig 8: Configuration of predictive model for USA and all products


Once this predictive model is trained, we have the predictive forecasts for 2021 for USA and all the car models as shown below.


Fig 9: Predictive forecasts for USA and all car models.


Then duplicate this predictive model. Open the status pane at the bottom, select the predictive model, and click the three dots on the right and choose Duplicate.


Fig 10: Duplicate the predictive model.


Set the new predictive model with all car models and group 3: FRANCE BELGIUM SWITZERLAND. Here again, we are below the limit on the number of entities.


Fig 11: Setting for predictive model for all car models and France, Belgium, and Switzerland.


Train this predictive model. Here the three countries are in the same group. It is the business choice I have made when I create the custom property. The data is aggregated for these three countries. This means that the predictive forecast for 2021 will be the same for each of these countries. When the predictive forecasts are saved into the planning model, they are equally spread across the three countries.


Fig 12: Predictive forecasts for all car models and France, Belgium, and Switzerland.


I continue this process for the three remaining groups. At the end there are five predictive models inside the Predictive Scenario. Each one has one thousand entities. Note: It is not necessary to wait for the end of the training to start a next one. The five predictive models can be trained in parallel.


Fig 13: The five predictive models


The last step is to sequentially apply these five predictive models to private version of the planning model to save the predictive forecasts inside the planning. Note: The application of a predictive model has to put a lock on the planning model to write the predictive forecasts. Once done, the lock is released. This is the reason the five predictive models must be applied in sequence.


Fig 14: Predictive forecasts applied to the planning. Predictive forecasts are equally spread over Belgium, France, and Switzerland


I hope you have appreciated this reading and that this way to bypass the restriction of one thousand entities is useful for you. I’d be  grateful if you leave a comment, and please don’t forget to like it. Thank you.

Resources to learn more about Predictive Planning.

 
5 Comments