edu.stanford.nlp.maxent.iis
Class ReadDataHPSGBinary

java.lang.Object
  |
  +--edu.stanford.nlp.maxent.iis.ReadDataHPSGBinary

public class ReadDataHPSGBinary
extends Object


Constructor Summary
ReadDataHPSGBinary()
           
ReadDataHPSGBinary(String wekaFileName)
           
ReadDataHPSGBinary(String wekaFileName, ReadDataHPSG train)
           
 
Method Summary
 void advanceData()
          read in the next data in currentData
 String getAttrName(int aNo, int val)
           
 int getClass(int exampleNo)
           
 DataDouble getData(int index)
           
 double getFValue(int aNo, int exampleNo)
           
 DataDouble getNextData()
           
 int getNumAttributes()
           
 int getNumValues(int aNo)
           
 String getYName(int yNo)
           
 boolean hasMoreData()
           
 boolean ignore(String s)
           
 boolean nominal(int aNo)
           
 boolean numeric(int aNo)
           
 int numSamples()
           
 void read(String filename)
           
 void readAttribute(String s)
          Parse an attribute specification.
 void readData(String s)
          reads one data instance - one line of the file adds the instance to the features which are non-zero for it also adds it to the list of instances for its class
 void save(String filename)
           
 void setFeatures()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReadDataHPSGBinary

public ReadDataHPSGBinary()

ReadDataHPSGBinary

public ReadDataHPSGBinary(String wekaFileName)
                   throws Exception

ReadDataHPSGBinary

public ReadDataHPSGBinary(String wekaFileName,
                          ReadDataHPSG train)
                   throws Exception
Method Detail

setFeatures

public void setFeatures()

hasMoreData

public boolean hasMoreData()

advanceData

public void advanceData()
read in the next data in currentData


getNextData

public DataDouble getNextData()

readData

public void readData(String s)
              throws Exception
reads one data instance - one line of the file adds the instance to the features which are non-zero for it also adds it to the list of instances for its class

Exception

numeric

public boolean numeric(int aNo)

nominal

public boolean nominal(int aNo)

ignore

public boolean ignore(String s)

getNumAttributes

public int getNumAttributes()

getNumValues

public int getNumValues(int aNo)

getFValue

public double getFValue(int aNo,
                        int exampleNo)

getClass

public int getClass(int exampleNo)

readAttribute

public void readAttribute(String s)
Parse an attribute specification. This reads a specification in the form \@attribute name real|nominal {val1,val2,..,valN}.


getYName

public String getYName(int yNo)

getAttrName

public String getAttrName(int aNo,
                          int val)

getData

public DataDouble getData(int index)

numSamples

public int numSamples()

save

public void save(String filename)

read

public void read(String filename)


Stanford NLP Group