Prediction in Dashboard
This document contains the information steps to get prediction data by applying set of input data using dataset. In order to get the prediction values against dataset, once must have prediction model ready which takes input and provide response against each input value. Here in OPNBI, we send the data inputs using dataset, add prediction model name and other couple of values and you will get the prediction values from model file directly in dashboard widget.
In this document, we will demonstrate prediction functionality using Product purchase prediction. It is one of our prediction models we have on the server which provides probability of product being purchase by a person.
This example predicts the product purchase probability of a person based on input parameters like gender, age, estimated salary. This example is based on the KNN classification model
Follow below steps
This Example is based on kNN Classification of Supervised Learning.
- Login to OPNBI with valid credentials
- Go to dashboard and create a new dashboard
- Add a table widget in dashboard and select dataset which has the input data for the prediction model. Note: Input data should be in format which is supported by prediction model. List of columns should be the same as prediction model supports.
- For the Demo purpose, we have a dataset named “kNN-1-Predict Product purchase based on social network Ad”.
- Select relevant dataset from the dropdown and add all the column in to table widget as shown in below image,
Click on save and exit and resize the table widget as per your convenience
Click on edit icon of the table widget to add prediction values and click on predict icon available just right of custom column option as shown in below image,
By clicking on predict option, prediction dialog box will appear which ask for prediction details,
This dialog box asks 4 inputs, URL: provide server URL where your prediction models are available or hosted. Demo URL we are using here is “https://aip.OPNBIhub.com:8000/”
Model Name: Model Name is the name of prediction model you are using. Generally, name is unique identifier for the prediction model which we have to pass in request. For this Demo it would be “knn1-product-purchase-prediction”.
Column Map: give a name of unique value by which each row is identified, for example serial number or customer number. In this Demo it would be customer ID
Predict columns: name of the column in which prediction model sends prediction value. In this Demo example, prediction model provides value in column named “Probability”. 10. Fill the required details as shown in below image,
NOTE: column name should be same as defined in prediction model otherwise it will not get the column data. (For both column Map and Predict Columns) 11. Click on save button to save the changes. After saving, again go to table edit view and scroll down in to selected column list in table and you can see a new column added named as Prediction.
Click on save and exit and go to dashboard preview. Check this prediction column against each customer ID and you will see prediction value against each customer ID based on various input values like Gender, Age and estimated salary.
Please note here, prediction value is completely based on prediction model, here it is showing values as 0 or 100 where 0 represents no probability and 100 represents possibility that customer will purchase the product.
Further user can use custom column to represent this value with icons and images in order to make it more visually attractive.