本文整理匯總了Java中com.rapidminer.example.table.BinominalMapping類的典型用法代碼示例。如果您正苦於以下問題:Java BinominalMapping類的具體用法?Java BinominalMapping怎麽用?Java BinominalMapping使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
BinominalMapping類屬於com.rapidminer.example.table包,在下文中一共展示了BinominalMapping類的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: MappingTranslation
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
public MappingTranslation(NominalMapping originalMapping) {
this.originalMapping = originalMapping;
if (originalMapping instanceof PolynominalMapping) {
this.newMapping = new PolynominalMapping();
} else {
this.newMapping = new BinominalMapping();
}
}
示例2: createBinominalValueAttribute
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
private Attribute createBinominalValueAttribute(Attribute attribute, String value) {
NominalMapping mapping = new BinominalMapping();
mapping.mapString("false");
mapping.mapString("true");
// giving new attributes old name_value
String newName = createAttributeName(attribute.getName(), value);
Attribute newAttribute = new ViewAttribute(this, attribute, newName, Ontology.BINOMINAL, mapping);
binominalAttributeValueMap.put(newAttribute, (double) attribute.getMapping().mapString(value));
return newAttribute;
}
示例3: XMLSerialization
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
private XMLSerialization(ClassLoader classLoader) {
try {
Class<?> xStreamClass = Class.forName("com.thoughtworks.xstream.XStream");
Class generalDriverClass = Class.forName("com.thoughtworks.xstream.io.HierarchicalStreamDriver");
Constructor constructor = xStreamClass.getConstructor(new Class[] { generalDriverClass });
Class driverClass = Class.forName("com.thoughtworks.xstream.io.xml.XppDriver");
xStream = (com.thoughtworks.xstream.XStream) constructor.newInstance(driverClass.newInstance());
xStream.setMode(com.thoughtworks.xstream.XStream.ID_REFERENCES);
// define default aliases here
addAlias("IOContainer", IOContainer.class);
addAlias("PolynominalAttribute", PolynominalAttribute.class);
addAlias("BinominalAttribute", BinominalAttribute.class);
addAlias("NumericalAttribute", NumericalAttribute.class);
addAlias("PolynominalMapping", PolynominalMapping.class);
addAlias("BinominalMapping", BinominalMapping.class);
addAlias("NumericalStatistics", NumericalStatistics.class);
addAlias("WeightedNumericalStatistics", WeightedNumericalStatistics.class);
addAlias("NominalStatistics", NominalStatistics.class);
addAlias("UnknownStatistics", UnknownStatistics.class);
addAlias("SimpleAttributes", SimpleAttributes.class);
addAlias("AttributeRole", AttributeRole.class);
xStream.setClassLoader(classLoader);
defineXMLAliasPairs();
} catch (Throwable e) {
// TODO: Why are we catching Throwables?
// LogService.getRoot().log(Level.WARNING,
// "Cannot initialize XML serialization. Probably the libraries 'xstream.jar' and 'xpp.jar' were not provided. XML serialization will not work!",
// e);
LogService.getRoot().log(
Level.WARNING,
I18N.getMessage(LogService.getRoot().getResourceBundle(),
"com.rapidminer.tools.XMLSerialization.writing_initializing_xml_serialization_error", e), e);
}
}
示例4: XMLSerialization
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
private XMLSerialization(ClassLoader classLoader) {
try {
Class<?> xStreamClass = Class.forName("com.thoughtworks.xstream.XStream");
Class<?> generalDriverClass = Class.forName("com.thoughtworks.xstream.io.HierarchicalStreamDriver");
Constructor<?> constructor = xStreamClass.getConstructor(generalDriverClass);
Class<?> driverClass = Class.forName("com.thoughtworks.xstream.io.xml.XppDriver");
xStream = (com.thoughtworks.xstream.XStream) constructor.newInstance(driverClass.newInstance());
xStream.setMode(com.thoughtworks.xstream.XStream.ID_REFERENCES);
// define default aliases here
addAlias("IOContainer", IOContainer.class);
addAlias("PolynominalAttribute", PolynominalAttribute.class);
addAlias("BinominalAttribute", BinominalAttribute.class);
addAlias("NumericalAttribute", NumericalAttribute.class);
addAlias("PolynominalMapping", PolynominalMapping.class);
addAlias("BinominalMapping", BinominalMapping.class);
addAlias("NumericalStatistics", NumericalStatistics.class);
addAlias("WeightedNumericalStatistics", WeightedNumericalStatistics.class);
addAlias("NominalStatistics", NominalStatistics.class);
addAlias("UnknownStatistics", UnknownStatistics.class);
addAlias("SimpleAttributes", SimpleAttributes.class);
addAlias("AttributeRole", AttributeRole.class);
xStream.setClassLoader(classLoader);
defineXMLAliasPairs();
} catch (Throwable e) {
// TODO: Why are we catching Throwables?
LogService.getRoot().log(Level.WARNING, I18N.getMessage(LogService.getRoot().getResourceBundle(),
"com.rapidminer.tools.XMLSerialization.writing_initializing_xml_serialization_error", e), e);
}
}
示例5: MappingTranslation
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
public MappingTranslation(NominalMapping originalMapping) {
this.originalMapping = originalMapping;
if (originalMapping instanceof PolynominalMapping) {
this.newMapping = new PolynominalMapping();
} else {
this.newMapping = new BinominalMapping();
}
}
示例6: XMLSerialization
import com.rapidminer.example.table.BinominalMapping; //導入依賴的package包/類
private XMLSerialization(ClassLoader classLoader) {
try {
Class<?> xStreamClass = Class.forName("com.thoughtworks.xstream.XStream");
Class generalDriverClass = Class.forName("com.thoughtworks.xstream.io.HierarchicalStreamDriver");
Constructor constructor = xStreamClass.getConstructor(new Class[] { generalDriverClass });
Class driverClass = Class.forName("com.thoughtworks.xstream.io.xml.XppDriver");
xStream = (com.thoughtworks.xstream.XStream)constructor.newInstance(driverClass.newInstance());
xStream.setMode(com.thoughtworks.xstream.XStream.ID_REFERENCES);
// define default aliases here
addAlias("IOContainer", IOContainer.class);
addAlias("PolynominalAttribute", PolynominalAttribute.class);
addAlias("BinominalAttribute", BinominalAttribute.class);
addAlias("NumericalAttribute", NumericalAttribute.class);
addAlias("PolynominalMapping", PolynominalMapping.class);
addAlias("BinominalMapping", BinominalMapping.class);
addAlias("NumericalStatistics", NumericalStatistics.class);
addAlias("WeightedNumericalStatistics", WeightedNumericalStatistics.class);
addAlias("NominalStatistics", NominalStatistics.class);
addAlias("UnknownStatistics", UnknownStatistics.class);
addAlias("SimpleAttributes", SimpleAttributes.class);
addAlias("AttributeRole", AttributeRole.class);
xStream.setClassLoader(classLoader);
defineXMLAliasPairs();
} catch (Throwable e) {
// TODO: Why are we catching Throwables?
//LogService.getRoot().log(Level.WARNING, "Cannot initialize XML serialization. Probably the libraries 'xstream.jar' and 'xpp.jar' were not provided. XML serialization will not work!", e);
LogService.getRoot().log(Level.WARNING,
I18N.getMessage(LogService.getRoot().getResourceBundle(),
"com.rapidminer.tools.XMLSerialization.writing_initializing_xml_serialization_error",
e),
e);
}
}