This content has been marked as final. Show 2 replies
If you are using Data Miner and build a AR model using the AR Build node, you can then connect a Model Details node to it.
This allows you to extract out details of the AR model as a flow of data, that you can then persist using Create Table if you wish.
Edit the Model Details node to select itemsets and then right click the Model Details node View Data option.
You can then view the generated SQL to see an example of how to access the itemset data as shown below.
You can follow the same approach for other models to get a feel for how to write the sql necessary to extract out model information.
WITH /* Start of sql for node: Model Details */
"N$10003" as (select "MODEL_SCHEMA",
"ATTRIBUTE_NUM_VALUE" from (SELECT CAST('DMUSER' AS VARCHAR2(30)) as "MODEL_SCHEMA",
CAST('AR_SH_SAMPLE' AS VARCHAR2(30)) as "MODEL_NAME",
itemset_id as "ID",
support as "SUPPORT",
number_of_items as "NUMBER_OF_ITEMS",
item.attribute_name as "ATTRIBUTE_NAME",
item.attribute_subname as "ATTRIBUTE_SUBNAME",
item.attribute_num_value as "ATTRIBUTE_NUM_VALUE",
item.attribute_str_value as "ATTRIBUTE_STR_VALUE"
FROM TABLE(dbms_data_mining.get_frequent_itemsets('"DMUSER"."AR_SH_SAMPLE"', NULL, NULL)) t,
/* End of sql for node: Model Details */
select * from "N$10003";