-
model
-
A unique name for the model.
-
column definition list
-
A comma-separated list of column definitions.
-
algorithm
-
The name of a data mining algorithm, as defined by the current provider.
-
parameter list
-
Optional. A comma-separated list of provider-defined parameters for the algorithm.
-
XML string
-
(For advanced use only.) An XML-encoded model (PMML). The string must be enclosed in single quotation marks (').
The SESSION clause lets you create a mining model that is automatically removed from the server when the connection closes or the session times out. SESSION mining models are useful because they do not require the user to be a database administrator, and they only use disk space for as long as the connection is open.
The WITH DRILLTHROUGH clause enables drill through on the new mining model. Drillthrough can only be enabled when you create the model. For some model types, drillthrough is required in order to browse the model in the custom viewer. Drillthrough is not required for prediction or for browsing the model by using the Microsoft Generic Content Tree Viewer.
The CREATE MINING MODEL statement creates a new mining model that is based on the column definition list, the algorithm, and the algorithm parameter list.
Column Definition List
You define the structure of a model that uses the column definition list by including the following information for each column:
-
Name (mandatory)
-
Data type (mandatory)
-
Distribution
-
List of modeling flags
-
Content type (mandatory)
-
Prediction request, which indicates to the algorithm to predict this column, indicated by the PREDICT or PREDICT_ONLY clause
-
Relationship to an attribute column (mandatory only if it applies), indicated by the RELATED TO clause
Use the following syntax for the column definition list, to define a single column:
<column name> <data type> [<Distribution>] [<Modeling Flags>] <Content Type> [<prediction>] [<column relationship>]
Use the following syntax for the column definition list, to define a nested table column:
<column name> TABLE [<prediction>] ( <non-table column definition list> )
Except for modeling flags, you can use no more than one clause from a particular group to define a column. You can define multiple modeling flags for a column.
For a list of the data types, content types, column distributions, and modeling flags that you can use to define a column, see the following topics:
You can add a clause to the statement to describe the relationship between two columns. Analysis Services supports the use of the following <Column relationship> clause.
-
RELATED TO
-
This form indicates a value hierarchy. The target of a RELATED TO column can be a key column in a nested table, a discretely-valued column in the case row, or another column with a RELATED TO clause, which indicates a deeper hierarchy.
Use a prediction clause to describe how the prediction column is used. The following table describes the two possible clauses.
|
<prediction> clause
|
Description
|
|---|
|
PREDICT
|
This column can be predicted by the model, and it can be supplied in input cases to predict the value of other predictable columns.
|
|
PREDICT_ONLY
|
This column can be predicted by the model, but its values cannot be used in input cases to predict the value of other predictable columns.
|
Parameter Definition List
You can use the parameter list to adjust the performance and functionality of a mining model. The syntax of the parameter list is as follows:
[<parameter> = <value>, <parameter> = <value>,…]
For a list of the parameters that are associated with each algorithm, see Data Mining Algorithms (Analysis Services - Data Mining).