Description: PREDICTION_BOUNDS returns an object with two NUMBER fields LOWER and UPPER. For a regression mining function, the bounds apply to value of the prediction. For a classification mining function, the bounds apply to the probability value. If the GLM was built using ridge regression, or if the covariance matrix is found to be singular during the build, then this function returns NULL for both fields.
For confidence_level, specify a number in the range (0,1). If you omit this clause, then the default value is 0.95.
The class_value argument is valid for classification models but not for regression models. By default, the function returns the bounds for the prediction with the highest probability. You can use the class_value argument to filter out the bounds value specific to a target value.
You can specify class_value while leaving confidence_level at its default by specifying NULL for confidence_level.
The following example returns the distribution of customers whose ages are predicted to be between 25 and 45 years with 98% confidence.
This example and the prerequisite data mining operations can be found in the demo file $ORACLE_HOME/rdbms/demo/dmglcdem.sql.
Language: PL/SQL Highlight Mode: PLSQL Last Modified: March 07th, 2009
USING <* | schema.TABLE.* | expression AS alias>SELECTCOUNT(cust_id) cust_count, cust_marital_status
FROM(SELECT cust_id, cust_marital_status
WHERE PREDICTION_BOUNDS(glmr_sh_regr_sample,0.98 USING *).LOWER>24AND
PREDICTION_BOUNDS(glmr_sh_regr_sample,0.98 USING *).UPPER<46)GROUPBY cust_marital_status;
-------------- --------------------46 NeverM
5 Separ.35 Divorc.72 Married
SQL University.net courses meet the most demanding needs of the business world for advanced education
in a cost-effective manner. SQL University.net courses are available immediately for IT professionals
and can be taken without disruption of your workplace schedule or processes.
Compared to traditional travel-based training, SQL University.net saves time and valuable corporate
resources, allowing companies to do more with less. That's our mission, and that's what we deliver.