Environment for
DeveLoping
KDD-Applications
Supported by Index-Structures

de.lmu.ifi.dbs.elki.parser
Class FloatVectorLabelParser

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.logging.AbstractLoggable
      extended by de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
          extended by de.lmu.ifi.dbs.elki.parser.AbstractParser<V>
              extended by de.lmu.ifi.dbs.elki.parser.RealVectorLabelParser<FloatVector>
                  extended by de.lmu.ifi.dbs.elki.parser.FloatVectorLabelParser
All Implemented Interfaces:
LinebasedParser<FloatVector>, Parser<FloatVector>, Parameterizable

public class FloatVectorLabelParser
extends RealVectorLabelParser<FloatVector>

Provides a parser for parsing one point per line, attributes separated by whitespace.

Numerical values in a line will be parsed as double values but used in float precision only.

Several labels may be given per point. A label must not be parseable as double. Lines starting with "#" will be ignored.

An index can be specified to identify an entry to be treated as class label. This index counts all entries (numeric and labels as well) starting with 0.

Author:
Arthur Zimek

Field Summary
 
Fields inherited from class de.lmu.ifi.dbs.elki.parser.RealVectorLabelParser
CLASS_LABEL_INDEX_PARAM, classLabelIndex
 
Fields inherited from class de.lmu.ifi.dbs.elki.parser.AbstractParser
ATTRIBUTE_CONCATENATION, COMMENT, WHITESPACE_PATTERN
 
Fields inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
optionHandler
 
Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debug, logger
 
Constructor Summary
FloatVectorLabelParser()
           
 
Method Summary
 FloatVector createDBObject(List<Double> attributes)
          Creates a FloatVector out of the given attribute values.
protected  String descriptionLineType()
           
 
Methods inherited from class de.lmu.ifi.dbs.elki.parser.RealVectorLabelParser
parse, parseLine, setParameters, shortDescription
 
Methods inherited from class de.lmu.ifi.dbs.elki.parser.AbstractParser
toString
 
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
addOption, addParameterizable, addParameterizable, checkGlobalParameterConstraints, collectOptions, getAttributeSettings, getParameters, rememberParametersExcept, removeOption, removeParameterizable
 
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debugFine, debugFiner, debugFinest, exception, progress, verbose, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.lmu.ifi.dbs.elki.utilities.optionhandling.Parameterizable
checkGlobalParameterConstraints, collectOptions, getParameters
 

Constructor Detail

FloatVectorLabelParser

public FloatVectorLabelParser()
Method Detail

createDBObject

public FloatVector createDBObject(List<Double> attributes)
Creates a FloatVector out of the given attribute values.

Specified by:
createDBObject in class RealVectorLabelParser<FloatVector>
Parameters:
attributes - the attributes of the vector to create.
Returns:
a RalVector of type V containing the given attribute values
See Also:
RealVectorLabelParser.createDBObject(java.util.List)

descriptionLineType

protected String descriptionLineType()
Specified by:
descriptionLineType in class RealVectorLabelParser<FloatVector>

Release 0.2 (2009-07-06_1820)