Senior SAP Architect
Predictive analytics encompasses a variety of predictive algorithms from predictive modeling, machine learning, and data mining that analyze current and historical facts to make predictions about future or otherwise unknown events.
SAP HANA delivered the Predictive Analysis Library (PAL), which contains a number of universal predictive algorithms that can execute directly against the data in HANA, includes classic and universal predictive analysis algorithms in nine data-mining categories:
- Time Series
- Social Network Analysis
The idea behind PAL is to make those algorithms very straightforward to execute on your data in HANA with a few lines of SQLScript. In most cases you just need to specify your data source (table or view), maintain a Parameter Table (parameters of the function), and identify an Output Table, and then let HANA PAL do the rest.
You can create a Predictive Analytical Model via Flowgraph Model tool as shown below:
With the help of flowgraph, you can easily create a model and generate the predict results:
- Specify Data Source, table or view based from HANA or BW schema
- Apply filter
- Aggregate over column
- Choose PAL function
- Maintain the parameters for the algorithm
- Generate Model and Forecasting data
Or you can write HANA SQL Script to call PAL functions or Procedures in HANA, which give you more flexibility. As call other stored procedures, you can specify the input table/view, parament table, returning of the statistics table and result table. The code should be something as below:
CALL P_LRDTSA (:v_input, :v_params, v_stats, v_results);
The results will be stored in result tables, you can present the forecasting data and actual data together in reporting tools, such as WebI, Design Studio, Lumira and PowerBI.
For more information, you may refer to SAP HANA Predictive Analysis Library help document at SAP help portal: https://help.sap.com/viewer/product/SAP_HANA_PLATFORM/1.0.12/en-US