Module datarush.analytics
Class PMMLClusteringModel
java.lang.Object
com.pervasive.datarush.analytics.pmml.PMMLModel
com.pervasive.datarush.analytics.cluster.PMMLClusteringModel
PMML clustering model. This model uses the standard PMML Clustering model.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class com.pervasive.datarush.analytics.pmml.PMMLModel
PMMLModel.MiningFunction -
Constructor Summary
ConstructorsConstructorDescriptionPMMLClusteringModel(Document document) Create aPMMLClusteringModelout of an PMML document -
Method Summary
Modifier and TypeMethodDescriptionstatic PMMLClusteringModel.Builderbuilder(PMMLModelSpec spec, ModelClass modelClass, ComparisonMeasure comparisonMeasure, Cluster[] clusters) Creates a builder that buildsPMMLClusteringModelinstances with the provided model specification, model class, comparison measure and clusters.protected voidbuildModelElement(Element element) Subclasses must implement this method to fill-in the contents of the model element.Gets the name of the algorithm used to create this modelGets theClusteringFields of this model.Cluster[]Gets theClusters of this model.Gets theComparisonMeasureof this model.Gets theMissingValueWeightsof this model.Get theModelClassof this model.protected StringReturn the element name of the primary model element associated with this PMMLGets the name of this model.booleanGets whether this model is scorable.protected voidparseModelElement(Element element) Parse the given model element into the respective model object.Methods inherited from class com.pervasive.datarush.analytics.pmml.PMMLModel
findModelElement, getAnnotationText, getModelExplanation, getModelSpec, getVersion, parse, setAnnotationText, setModelExplanation, setVersion, toPMML
-
Constructor Details
-
PMMLClusteringModel
Create aPMMLClusteringModelout of an PMML document- Parameters:
document- the document containing the PMML model
-
-
Method Details
-
getModelName
Gets the name of this model.- Returns:
- the name of this model
-
getAlgorithmName
Gets the name of the algorithm used to create this model- Returns:
- the name of the algorithm used to create this model
-
getModelClass
Get theModelClassof this model.- Returns:
- the
ModelClassof this model
-
isScorable
public boolean isScorable()Gets whether this model is scorable.- Returns:
- true, if the model is scorable, false otherwise
-
getClusteringFields
Gets theClusteringFields of this model.- Returns:
- the
ClusteringFields of this model
-
getMissingValueWeights
Gets theMissingValueWeightsof this model.- Returns:
- the
MissingValueWeightsof this model
-
getClusters
Gets theClusters of this model.- Returns:
- the
Clusters of this model
-
getComparisonMeasure
Gets theComparisonMeasureof this model.- Returns:
- the
ComparisonMeasureof this model
-
buildModelElement
Description copied from class:PMMLModelSubclasses must implement this method to fill-in the contents of the model element. At the time this method is invoked, the element will have its name and MiningSchema sub-element populated.- Specified by:
buildModelElementin classPMMLModel- Parameters:
element- the model element
-
getModelElementName
Description copied from class:PMMLModelReturn the element name of the primary model element associated with this PMML- Specified by:
getModelElementNamein classPMMLModel- Returns:
- the element name of the primary model element
-
parseModelElement
Description copied from class:PMMLModelParse the given model element into the respective model object.- Specified by:
parseModelElementin classPMMLModel- Parameters:
element- root element of model object
-
builder
public static PMMLClusteringModel.Builder builder(PMMLModelSpec spec, ModelClass modelClass, ComparisonMeasure comparisonMeasure, Cluster[] clusters) Creates a builder that buildsPMMLClusteringModelinstances with the provided model specification, model class, comparison measure and clusters. For other parameters defaults, will be used: the model will be scorable, have no name or algorithm name, no clustering fields, and its missing value weights element will have an empty weights array.- Parameters:
spec- thePMMLModelSpecmodelClass- theModelClasscomparisonMeasure- theComparisonMeasureclusters- theClusters- Returns:
PMMLClusteringModel.Builder
-