cancel
Showing results for 
Search instead for 
Did you mean: 

Can we use PAL in Abap

Joseph_BERTHE
Active Contributor

Hello all,


My question is in the title. I have done some research but I didn't find an answer. So, hope if someone have one 🙂

If it is not possible to do predictive analisys in Abap, I would like to know if it is mandatory to copy data from Abap schema to an Hana schema to do analysis?

Or, how can we do or use PAL on data in ABAP schema ?

Kind regards,

Joseph

DoanManhQuynh
Active Contributor
0 Kudos

Within SAP BW there is SAP HANA Analysis Process which can call PAL directly, so I think might be there is a way to use it from SAP side using ABAP...Maybe you can debug it...

Joseph_BERTHE
Active Contributor
0 Kudos

Thanks, but I don't have BW 🙂

Accepted Solutions (1)

Accepted Solutions (1)

AndreasForster
Product and Topic Expert
Product and Topic Expert

Hi Joseph, PAL is a framework in SAP HANA, so the data needs to be in HANA to use PAL. But the PAL algorithms can be called through SQL, hence it should be possible for ABAP to interact with them
https://help.sap.com/viewer/2cfbc5cf2bc14f028cfbe2a2bba60a50/latest/en-US/f652a8186a144e929a1ade7a3c...
There is also a new Python wrapper for PAL which is very easy to use. Not sure if this fits into your project, but it could be an option to test out PAL algorithms quickly through Python before implementing through ABAP / SQL.
https://help.sap.com/doc/0172e3957b5946da85d3fde85ee8f33d/latest/en-US/html/hana_ml.html
Many Greetings, Andreas

Joseph_BERTHE
Active Contributor

Hello Andreas,

Thanks for your documented answer.

In fact, I fill like it is quite "Geeky"... 🙂 My requirement seams to be very easy : "I have to provide a Material quantity to my user for its Purchase Order. That quantity should be predict from the last orders (since last 2 years) with that material." Curently I do a simple average function in SQL but it is not very clever, so I ask to myself if it is not possible to use PAL and predict the rigth material qantity...

And If I have to copy all the orders containing that material into an HANA table and then do PAL algorithims.... In that case I'm not "in real time" and there is lot of duplicate information.

Maybe I miss understood the theory of PA, if you have some insigth which can help me to solve my requirement with PA.

Kind regards,

Joseph

AndreasForster
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Joseph, the geeky stuff is typically the fun stuff!
If the orders are placed regularly, ie weekly, a time series forecast could help. Then for each product you would have only around 100 values for the two years. This could be passed on the fly to PAL to create a forecast for the next week's order amount. The PAL documentation has a whole section on time series, ie ARIMA is very common.
Another approach, if the orders not very regular, could be a regression estimate. You could use the number of days that passed from the last order as predictor and the order quantity as target. Then when the next order is placed, the model predicts the quantity depending on how long ago the last order was placed.
This could be further extended, ie by taking into account the quantities that are left in stock, or information on known future consumption.... Sounds like plenty of fun 🙂

Many Greetings, Andreas

Answers (0)