Package ubic.gemma.core.loader.genome
Class BlatResultParser
java.lang.Object
ubic.gemma.core.loader.util.parser.BasicLineParser<BlatResult>
ubic.gemma.core.loader.genome.BlatResultParser
- All Implemented Interfaces:
LineParser<BlatResult>
,Parser<BlatResult>
Loader to handle results generated by Jim Kent's Blat.
The PSL file format is described at ucsc format faq and
golden path blat spec. Blank lines are skipped as are valid PSL headers.
Target sequences are assumed to be chromosomes. If a chromosome name (chr10 or chr10.fa) is detected, the name is
stripped to be a chromosome number only (e.g. 10). Otherwise, the value is used as is. If the query name starts with
"target:", this is removed.
Results can be filtered by setting the scoreThreshold parameter.
- Author:
- pavlidis
-
Field Summary
Fields inherited from class ubic.gemma.core.loader.util.parser.BasicLineParser
log
Fields inherited from interface ubic.gemma.core.loader.util.parser.LineParser
MIN_PARSED_LINES_FOR_UPDATE, PARSE_ALERT_TIME_FREQUENCY_MS
Fields inherited from interface ubic.gemma.core.loader.util.parser.Parser
PARSE_ALERT_FREQUENCY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addResult
(BlatResult obj) static String
cleanUpQueryName
(String queryName) int
getTaxon()
parseOneLine
(String line) Handle the parsing of a single line from the input.void
setScoreThreshold
(double score) void
setSearchedDatabase
(ExternalDatabase searchedDatabase) void
Methods inherited from class ubic.gemma.core.loader.util.parser.BasicLineParser
parse, parse, parse
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface ubic.gemma.core.loader.util.parser.Parser
getUniqueResult
-
Constructor Details
-
BlatResultParser
public BlatResultParser()
-
-
Method Details
-
cleanUpQueryName
-
getNumSkipped
public int getNumSkipped() -
getResults
- Specified by:
getResults
in interfaceParser<BlatResult>
- Specified by:
getResults
in classBasicLineParser<BlatResult>
- Returns:
- the results of the parse.
-
addResult
- Specified by:
addResult
in classBasicLineParser<BlatResult>
-
getSearchedDatabase
- Returns:
- the searchedDatabase
-
setSearchedDatabase
- Parameters:
searchedDatabase
- the searchedDatabase to set
-
getTaxon
- Returns:
- the taxon
-
setTaxon
- Parameters:
taxon
- the taxon to set
-
parseOneLine
Description copied from interface:LineParser
Handle the parsing of a single line from the input.- Parameters:
line
- line to parse- Returns:
- parsed object
-
setScoreThreshold
public void setScoreThreshold(double score) - Parameters:
score
- Define a threshold, below which results are ignored. By default all results are read in.
-