Package edu.msu.cme.rdp.classifier.train
Class TreeFactory
- java.lang.Object
-
- edu.msu.cme.rdp.classifier.train.TreeFactory
-
public class TreeFactory extends java.lang.ObjectA TreeFactory reads the raw taxonomic information and creates the RawHierarchyTree nodes.
-
-
Constructor Summary
Constructors Constructor Description TreeFactory(java.io.Reader taxReader, int trainsetNo, java.lang.String version, java.lang.String modification)Creates new TreeFactory.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RawHierarchyTreegetRoot()Gets the root of the treevoidparseCopyNumberFile(java.lang.String cnFile)parse the copy number file first step, take the copy number info from the lowest rank taxa, then calculate the copy number of the parent taxa based on the immediate children second step, for any taxon without copy number info, uses thevoidparseSequenceFile(LineageSequenceParser parser)
-
-
-
Constructor Detail
-
TreeFactory
public TreeFactory(java.io.Reader taxReader, int trainsetNo, java.lang.String version, java.lang.String modification) throws java.io.IOException, NameRankDupExceptionCreates new TreeFactory.- Throws:
java.io.IOExceptionNameRankDupException
-
-
Method Detail
-
parseSequenceFile
public void parseSequenceFile(LineageSequenceParser parser) throws java.io.IOException
- Throws:
java.io.IOException
-
parseCopyNumberFile
public void parseCopyNumberFile(java.lang.String cnFile) throws java.io.IOExceptionparse the copy number file first step, take the copy number info from the lowest rank taxa, then calculate the copy number of the parent taxa based on the immediate children second step, for any taxon without copy number info, uses the- Parameters:
cnFile-- Throws:
java.io.IOException
-
getRoot
public RawHierarchyTree getRoot()
Gets the root of the tree
-
-