|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.ac.sanger.psu.gfmerge.util.biotools.BioTools
public class BioTools
class BioTools contains basic processing tools within GFMerge.
Constructor Summary | |
---|---|
BioTools()
|
Method Summary | |
---|---|
static MyTreeMap |
addToTreeMap(MyTreeMap tMap,
java.util.ArrayList locatableArrList)
AddToTreeMap method creates a binary tree of locateable objects sorted by their start location. |
static org.biojava.bio.seq.Sequence |
createNewSeqOfPickedGms(org.biojava.bio.seq.Sequence thisPredSeq,
java.util.ArrayList thisRegionsOfPickedGmsArr)
method which creates sequence object of a sequence and picked genemodels. |
private static java.util.ArrayList |
find(LocateAble obj,
java.util.HashMap doneObjects,
MyTreeMap tMap)
Find method contains recursive search for regions. |
private static java.util.ArrayList |
findOverlaps(LocateAble obj,
MyTreeMap tMap)
FindOverlaps method returns all overlapping objects in tree of objects. |
static java.lang.String |
getGenePredicterFromSequence(org.biojava.bio.seq.Sequence _sequence,
java.lang.String _fname)
method returns genefinder name of geneprediction if all features have the same 'method' value in the prediction file otherwise it throughs an exception. |
static boolean |
overlaps(org.biojava.bio.symbol.Location locOrg,
org.biojava.bio.symbol.Location locComp)
Overlaps method contains the BioJava overlap functionality and checks whether one location is contained by the other |
static java.util.ArrayList |
search(MyTreeMap tMap)
Search method calculates regions of overlapping features. |
static org.biojava.bio.seq.Sequence |
seqs2Seq(org.biojava.bio.seq.SequenceIterator sequences)
Seq2Seq method returns a sequence object when sequence iterator is given. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BioTools()
Method Detail |
---|
public static org.biojava.bio.seq.Sequence seqs2Seq(org.biojava.bio.seq.SequenceIterator sequences) throws org.biojava.bio.BioException
Called by the main method in GFMerge.
sequences
- SequenceIterator object which may contain more than one
more than one sequence, but only the first sequence is returned
org.biojava.bio.BioException
SequenceIterator
,
Sequence
public static java.lang.String getGenePredicterFromSequence(org.biojava.bio.seq.Sequence _sequence, java.lang.String _fname)
Called by the main method in GFMerge.
_sequence
- Sequence object_fname
- filename of the prediction file which is needed for
the exception method
java.util.NoSuchElementException
- If no method entry is in file
"Exception"
- If different method values are in fileSequence
public static org.biojava.bio.seq.Sequence createNewSeqOfPickedGms(org.biojava.bio.seq.Sequence thisPredSeq, java.util.ArrayList thisRegionsOfPickedGmsArr)
thisPredSeq
- BioJava sequence objectthisRegionsOfPickedGmsArr
- ArrayList of genemodel regions
containing highscoring genemodels
public static java.util.ArrayList search(MyTreeMap tMap)
Recursive computing of features sorted by start position in order to retrieve regions of continuously overlapping features (genemodel, cDNA, Blast)
tMap
- binary tree instanced from MyTreeMap
each
key-value-pair contains the start location of features as key and an
array of LocateAble
as value
ArrayList
of Regions which contain themselves
LocateAble objectsMyTreeMap
,
LocateAble
private static java.util.ArrayList find(LocateAble obj, java.util.HashMap doneObjects, MyTreeMap tMap)
Called by the search method in BioTools.
obj
- feature object with Location (genemodel, cDNA, Blast)doneObjects
- HashMap of seen objectstMap
- binary tree instanced from MyTreeMap
each
key-value-pair contains the start location of features as key and an
array of LocateAble
as valuegm
- objects of LocateAble
for which overlaps are
searched fordoneObjs
- tree of HashMap
which contains processed
objects
ArrayList
of regions which are list of overlapping
LocateAble objectsprivate static java.util.ArrayList findOverlaps(LocateAble obj, MyTreeMap tMap)
Called by the find method in BioTools.
obj
- objects of LocateAble
for which overlaps are searched
fortMap
- binary tree instanced from MyTreeMap
each
key-value-pair contains the start location of features as key and an
array of LocateAble
as value
ArrayList
of LocateAble objects which overlap a
certain LocateAble objectpublic static boolean overlaps(org.biojava.bio.symbol.Location locOrg, org.biojava.bio.symbol.Location locComp)
It was introduced because BioJava just compares sub locations and does not consider overlaps of introns
locOrg
- original locationlocComp
- location to compare
public static MyTreeMap addToTreeMap(MyTreeMap tMap, java.util.ArrayList locatableArrList)
Key is the start location of a LocateAble object, Value is an array of LocateAble objects with the same start location
tMap
- binary tree instanced from MyTreeMap
each
key-value-pair contains the start location of features as key and an
array of LocateAble
as value. tree is empty when called first,
new leaves will be added.locatableArrList
- ArrayList
of LocateAble objects
MyTreeMap
,
LocateAble
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |