Package edu.msu.cme.rdp.classifier.io

## Class GenusWordProbFileParser

- java.lang.Object
- - edu.msu.cme.rdp.classifier.io.GenusWordProbFileParser

    public class GenusWordProbFileParser
    extends java.lang.Object

A parser to parse a reader containing a list of the indices of genus nodes and the conditional probabilities that genus nodes contains the words.

### Constructor Summary

Constructors
`GenusWordProbFileParser()`

### Method Summary

All Methods Static Methods Concrete Methods
`static HierarchyVersion` `createGenusWordProbList​(java.io.Reader r, java.util.List<GenusWordConditionalProb> aList, HierarchyVersion version)` Reads a file and saves GenusWordConditionalProb objects in a list.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### GenusWordProbFileParser

    public GenusWordProbFileParser()

### Method Detail

#### createGenusWordProbList

    public static HierarchyVersion createGenusWordProbList​(java.io.Reader r,
                                                           java.util.List<GenusWordConditionalProb> aList,
                                                           HierarchyVersion version)
                                                    throws java.io.IOException,
                                                           TrainingDataException

Reads a file and saves GenusWordConditionalProb objects in a list. Returns the version information for validation purpose. The input file format: integer follows by a tab and float each line. The first value indicates the index of a genus node, the second value indicates the conditional probability that genus node contains the word.

Throws:
  `java.io.IOException`
  `TrainingDataException`