All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.dmg.pmml.PredictiveModelQuality Maven / Gradle / Ivy

There is a newer version: 1.6.5
Show newest version

package org.dmg.pmml;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlTransient;
import javax.xml.bind.annotation.XmlType;
import com.sun.xml.bind.Locatable;
import com.sun.xml.bind.annotation.XmlLocation;
import org.jpmml.schema.Added;
import org.jpmml.schema.Version;
import org.xml.sax.Locator;


/**
 * 

Java class for anonymous complex type. * *

The following schema fragment specifies the expected content contained within this class. * *

 * <complexType>
 *   <complexContent>
 *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
 *       <sequence>
 *         <element ref="{http://www.dmg.org/PMML-4_2}Extension" maxOccurs="unbounded" minOccurs="0"/>
 *         <element ref="{http://www.dmg.org/PMML-4_2}ConfusionMatrix" minOccurs="0"/>
 *         <element ref="{http://www.dmg.org/PMML-4_2}LiftData" minOccurs="0"/>
 *         <element ref="{http://www.dmg.org/PMML-4_2}ROC" minOccurs="0"/>
 *       </sequence>
 *       <attribute name="targetField" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
 *       <attribute name="dataName" type="{http://www.w3.org/2001/XMLSchema}string" />
 *       <attribute name="dataUsage" default="training">
 *         <simpleType>
 *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
 *             <enumeration value="training"/>
 *             <enumeration value="test"/>
 *             <enumeration value="validation"/>
 *           </restriction>
 *         </simpleType>
 *       </attribute>
 *       <attribute name="meanError" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="meanAbsoluteError" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="meanSquaredError" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="rootMeanSquaredError" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="r-squared" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="adj-r-squared" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="sumSquaredError" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="sumSquaredRegression" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="numOfRecords" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="numOfRecordsWeighted" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="numOfPredictors" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="degreesOfFreedom" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="fStatistic" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="AIC" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="BIC" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *       <attribute name="AICc" type="{http://www.dmg.org/PMML-4_2}NUMBER" />
 *     </restriction>
 *   </complexContent>
 * </complexType>
 * 
* * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "extensions", "confusionMatrix", "liftData", "roc" }) @XmlRootElement(name = "PredictiveModelQuality") @Added(Version.PMML_4_0) public class PredictiveModelQuality extends PMMLObject implements Locatable, HasExtensions { @XmlElement(name = "Extension") protected List extensions; @XmlElement(name = "ConfusionMatrix") protected ConfusionMatrix confusionMatrix; @XmlElement(name = "LiftData") protected LiftData liftData; @XmlElement(name = "ROC") protected ROC roc; @XmlAttribute(name = "targetField", required = true) protected String targetField; @XmlAttribute(name = "dataName") protected String dataName; @XmlAttribute(name = "dataUsage") protected String dataUsage; @XmlAttribute(name = "meanError") protected Double meanError; @XmlAttribute(name = "meanAbsoluteError") protected Double meanAbsoluteError; @XmlAttribute(name = "meanSquaredError") protected Double meanSquaredError; @XmlAttribute(name = "rootMeanSquaredError") @Added(Version.PMML_4_1) protected Double rootMeanSquaredError; @XmlAttribute(name = "r-squared") protected Double rSquared; @XmlAttribute(name = "adj-r-squared") @Added(Version.PMML_4_1) protected Double adjRSquared; @XmlAttribute(name = "sumSquaredError") @Added(Version.PMML_4_1) protected Double sumSquaredError; @XmlAttribute(name = "sumSquaredRegression") @Added(Version.PMML_4_1) protected Double sumSquaredRegression; @XmlAttribute(name = "numOfRecords") @Added(Version.PMML_4_1) protected Double numOfRecords; @XmlAttribute(name = "numOfRecordsWeighted") @Added(Version.PMML_4_1) protected Double numOfRecordsWeighted; @XmlAttribute(name = "numOfPredictors") @Added(Version.PMML_4_1) protected Double numOfPredictors; @XmlAttribute(name = "degreesOfFreedom") @Added(Version.PMML_4_1) protected Double degreesOfFreedom; @XmlAttribute(name = "fStatistic") @Added(Version.PMML_4_1) protected Double fStatistic; @XmlAttribute(name = "AIC") @Added(Version.PMML_4_1) protected Double aic; @XmlAttribute(name = "BIC") @Added(Version.PMML_4_1) protected Double bic; @XmlAttribute(name = "AICc") @Added(Version.PMML_4_1) protected Double aiCc; @XmlLocation @XmlTransient protected Locator locator; public PredictiveModelQuality() { super(); } public PredictiveModelQuality(final String targetField) { super(); this.targetField = targetField; } /** * Gets the value of the extensions property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the extensions property. * *

* For example, to add a new item, do as follows: *

     *    getExtensions().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link Extension } * * */ public List getExtensions() { if (extensions == null) { extensions = new ArrayList(); } return this.extensions; } /** * Gets the value of the confusionMatrix property. * * @return * possible object is * {@link ConfusionMatrix } * */ public ConfusionMatrix getConfusionMatrix() { return confusionMatrix; } /** * Sets the value of the confusionMatrix property. * * @param value * allowed object is * {@link ConfusionMatrix } * */ public void setConfusionMatrix(ConfusionMatrix value) { this.confusionMatrix = value; } /** * Gets the value of the liftData property. * * @return * possible object is * {@link LiftData } * */ public LiftData getLiftData() { return liftData; } /** * Sets the value of the liftData property. * * @param value * allowed object is * {@link LiftData } * */ public void setLiftData(LiftData value) { this.liftData = value; } /** * Gets the value of the roc property. * * @return * possible object is * {@link ROC } * */ public ROC getROC() { return roc; } /** * Sets the value of the roc property. * * @param value * allowed object is * {@link ROC } * */ public void setROC(ROC value) { this.roc = value; } /** * Gets the value of the targetField property. * * @return * possible object is * {@link String } * */ public String getTargetField() { return targetField; } /** * Sets the value of the targetField property. * * @param value * allowed object is * {@link String } * */ public void setTargetField(String value) { this.targetField = value; } /** * Gets the value of the dataName property. * * @return * possible object is * {@link String } * */ public String getDataName() { return dataName; } /** * Sets the value of the dataName property. * * @param value * allowed object is * {@link String } * */ public void setDataName(String value) { this.dataName = value; } /** * Gets the value of the dataUsage property. * * @return * possible object is * {@link String } * */ public String getDataUsage() { if (dataUsage == null) { return "training"; } else { return dataUsage; } } /** * Sets the value of the dataUsage property. * * @param value * allowed object is * {@link String } * */ public void setDataUsage(String value) { this.dataUsage = value; } /** * Gets the value of the meanError property. * * @return * possible object is * {@link Double } * */ public Double getMeanError() { return meanError; } /** * Sets the value of the meanError property. * * @param value * allowed object is * {@link Double } * */ public void setMeanError(Double value) { this.meanError = value; } /** * Gets the value of the meanAbsoluteError property. * * @return * possible object is * {@link Double } * */ public Double getMeanAbsoluteError() { return meanAbsoluteError; } /** * Sets the value of the meanAbsoluteError property. * * @param value * allowed object is * {@link Double } * */ public void setMeanAbsoluteError(Double value) { this.meanAbsoluteError = value; } /** * Gets the value of the meanSquaredError property. * * @return * possible object is * {@link Double } * */ public Double getMeanSquaredError() { return meanSquaredError; } /** * Sets the value of the meanSquaredError property. * * @param value * allowed object is * {@link Double } * */ public void setMeanSquaredError(Double value) { this.meanSquaredError = value; } /** * Gets the value of the rootMeanSquaredError property. * * @return * possible object is * {@link Double } * */ public Double getRootMeanSquaredError() { return rootMeanSquaredError; } /** * Sets the value of the rootMeanSquaredError property. * * @param value * allowed object is * {@link Double } * */ public void setRootMeanSquaredError(Double value) { this.rootMeanSquaredError = value; } /** * Gets the value of the rSquared property. * * @return * possible object is * {@link Double } * */ public Double getRSquared() { return rSquared; } /** * Sets the value of the rSquared property. * * @param value * allowed object is * {@link Double } * */ public void setRSquared(Double value) { this.rSquared = value; } /** * Gets the value of the adjRSquared property. * * @return * possible object is * {@link Double } * */ public Double getAdjRSquared() { return adjRSquared; } /** * Sets the value of the adjRSquared property. * * @param value * allowed object is * {@link Double } * */ public void setAdjRSquared(Double value) { this.adjRSquared = value; } /** * Gets the value of the sumSquaredError property. * * @return * possible object is * {@link Double } * */ public Double getSumSquaredError() { return sumSquaredError; } /** * Sets the value of the sumSquaredError property. * * @param value * allowed object is * {@link Double } * */ public void setSumSquaredError(Double value) { this.sumSquaredError = value; } /** * Gets the value of the sumSquaredRegression property. * * @return * possible object is * {@link Double } * */ public Double getSumSquaredRegression() { return sumSquaredRegression; } /** * Sets the value of the sumSquaredRegression property. * * @param value * allowed object is * {@link Double } * */ public void setSumSquaredRegression(Double value) { this.sumSquaredRegression = value; } /** * Gets the value of the numOfRecords property. * * @return * possible object is * {@link Double } * */ public Double getNumOfRecords() { return numOfRecords; } /** * Sets the value of the numOfRecords property. * * @param value * allowed object is * {@link Double } * */ public void setNumOfRecords(Double value) { this.numOfRecords = value; } /** * Gets the value of the numOfRecordsWeighted property. * * @return * possible object is * {@link Double } * */ public Double getNumOfRecordsWeighted() { return numOfRecordsWeighted; } /** * Sets the value of the numOfRecordsWeighted property. * * @param value * allowed object is * {@link Double } * */ public void setNumOfRecordsWeighted(Double value) { this.numOfRecordsWeighted = value; } /** * Gets the value of the numOfPredictors property. * * @return * possible object is * {@link Double } * */ public Double getNumOfPredictors() { return numOfPredictors; } /** * Sets the value of the numOfPredictors property. * * @param value * allowed object is * {@link Double } * */ public void setNumOfPredictors(Double value) { this.numOfPredictors = value; } /** * Gets the value of the degreesOfFreedom property. * * @return * possible object is * {@link Double } * */ public Double getDegreesOfFreedom() { return degreesOfFreedom; } /** * Sets the value of the degreesOfFreedom property. * * @param value * allowed object is * {@link Double } * */ public void setDegreesOfFreedom(Double value) { this.degreesOfFreedom = value; } /** * Gets the value of the fStatistic property. * * @return * possible object is * {@link Double } * */ public Double getFStatistic() { return fStatistic; } /** * Sets the value of the fStatistic property. * * @param value * allowed object is * {@link Double } * */ public void setFStatistic(Double value) { this.fStatistic = value; } /** * Gets the value of the aic property. * * @return * possible object is * {@link Double } * */ public Double getAIC() { return aic; } /** * Sets the value of the aic property. * * @param value * allowed object is * {@link Double } * */ public void setAIC(Double value) { this.aic = value; } /** * Gets the value of the bic property. * * @return * possible object is * {@link Double } * */ public Double getBIC() { return bic; } /** * Sets the value of the bic property. * * @param value * allowed object is * {@link Double } * */ public void setBIC(Double value) { this.bic = value; } /** * Gets the value of the aiCc property. * * @return * possible object is * {@link Double } * */ public Double getAICc() { return aiCc; } /** * Sets the value of the aiCc property. * * @param value * allowed object is * {@link Double } * */ public void setAICc(Double value) { this.aiCc = value; } public PredictiveModelQuality withExtensions(Extension... values) { if (values!= null) { for (Extension value: values) { getExtensions().add(value); } } return this; } public PredictiveModelQuality withExtensions(Collection values) { if (values!= null) { getExtensions().addAll(values); } return this; } public PredictiveModelQuality withConfusionMatrix(ConfusionMatrix value) { setConfusionMatrix(value); return this; } public PredictiveModelQuality withLiftData(LiftData value) { setLiftData(value); return this; } public PredictiveModelQuality withROC(ROC value) { setROC(value); return this; } public PredictiveModelQuality withTargetField(String value) { setTargetField(value); return this; } public PredictiveModelQuality withDataName(String value) { setDataName(value); return this; } public PredictiveModelQuality withDataUsage(String value) { setDataUsage(value); return this; } public PredictiveModelQuality withMeanError(Double value) { setMeanError(value); return this; } public PredictiveModelQuality withMeanAbsoluteError(Double value) { setMeanAbsoluteError(value); return this; } public PredictiveModelQuality withMeanSquaredError(Double value) { setMeanSquaredError(value); return this; } public PredictiveModelQuality withRootMeanSquaredError(Double value) { setRootMeanSquaredError(value); return this; } public PredictiveModelQuality withRSquared(Double value) { setRSquared(value); return this; } public PredictiveModelQuality withAdjRSquared(Double value) { setAdjRSquared(value); return this; } public PredictiveModelQuality withSumSquaredError(Double value) { setSumSquaredError(value); return this; } public PredictiveModelQuality withSumSquaredRegression(Double value) { setSumSquaredRegression(value); return this; } public PredictiveModelQuality withNumOfRecords(Double value) { setNumOfRecords(value); return this; } public PredictiveModelQuality withNumOfRecordsWeighted(Double value) { setNumOfRecordsWeighted(value); return this; } public PredictiveModelQuality withNumOfPredictors(Double value) { setNumOfPredictors(value); return this; } public PredictiveModelQuality withDegreesOfFreedom(Double value) { setDegreesOfFreedom(value); return this; } public PredictiveModelQuality withFStatistic(Double value) { setFStatistic(value); return this; } public PredictiveModelQuality withAIC(Double value) { setAIC(value); return this; } public PredictiveModelQuality withBIC(Double value) { setBIC(value); return this; } public PredictiveModelQuality withAICc(Double value) { setAICc(value); return this; } public Locator sourceLocation() { return locator; } public void setSourceLocation(Locator newLocator) { locator = newLocator; } @Override public VisitorAction accept(Visitor visitor) { VisitorAction status = visitor.visit(this); for (int i = 0; (((status == VisitorAction.CONTINUE)&&(this.extensions!= null))&&(i





© 2015 - 2024 Weber Informatics LLC | Privacy Policy