Class AffyProbeReader
- java.lang.Object
-
- ubic.gemma.core.loader.util.parser.BasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
- ubic.gemma.core.loader.expression.arrayDesign.AffyProbeReader
-
- All Implemented Interfaces:
LineParser<Collection<Reporter>>,Parser<Collection<Reporter>>
public class AffyProbeReader extends BasicLineMapParser<CompositeSequence,Collection<Reporter>>
Reads Affymetrix Probe files, including exon arrays.Expected format is tabbed, NOT FASTA. A one-line header starting with the word "Probe" is REQUIRED. In later versions of the format the second field of the file (column) is omitted.
For 3' arrays, here is an example:
1494_f_at 1 325 359 1118 TCCCCATGAGTTTGGCCCGCAGAGT Antisense
For exon arrays, we create the equivalent files from the GFF files provided by Affymetrix. The files are created off-line using a PERL script.- Author:
- pavlidis
-
-
Field Summary
-
Fields inherited from class ubic.gemma.core.loader.util.parser.BasicLineMapParser
COMMENT_MARK, 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 Constructor Description AffyProbeReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontainsKey(CompositeSequence key)Collection<Reporter>get(CompositeSequence key)protected CompositeSequencegetKey(Collection<Reporter> newItem)Collection<CompositeSequence>getKeySet()Collection<Collection<Reporter>>getResults()voidparse(InputStream is)Parse aInputStream.Collection<Reporter>parseOneLine(String line)Handle the parsing of a single line from the input.protected voidput(CompositeSequence key, Collection<Reporter> value)voidsetSequenceField(int sequenceField)Set the index (starting from zero) of the field where the sequence is found.-
Methods inherited from class ubic.gemma.core.loader.util.parser.BasicLineMapParser
parse, parse
-
-
-
-
Method Detail
-
setSequenceField
public void setSequenceField(int sequenceField)
Set the index (starting from zero) of the field where the sequence is found. This varies in the Affymetrix-provided files.- Parameters:
sequenceField- sequence field
-
containsKey
public boolean containsKey(CompositeSequence key)
- Specified by:
containsKeyin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
get
public Collection<Reporter> get(CompositeSequence key)
- Specified by:
getin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
getKeySet
public Collection<CompositeSequence> getKeySet()
- Specified by:
getKeySetin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
getResults
public Collection<Collection<Reporter>> getResults()
- Specified by:
getResultsin interfaceParser<Collection<Reporter>>- Specified by:
getResultsin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>- Returns:
- the results of the parse.
-
parse
public void parse(InputStream is) throws IOException
Description copied from interface:ParserParse aInputStream.- Specified by:
parsein interfaceParser<Collection<Reporter>>- Overrides:
parsein classBasicLineMapParser<CompositeSequence,Collection<Reporter>>- Parameters:
is- input stream- Throws:
IOException- if there is a problem while manipulating the file
-
parseOneLine
public Collection<Reporter> parseOneLine(String line)
Description copied from interface:LineParserHandle the parsing of a single line from the input.- Specified by:
parseOneLinein interfaceLineParser<Collection<Reporter>>- Specified by:
parseOneLinein classBasicLineMapParser<CompositeSequence,Collection<Reporter>>- Parameters:
line- line to parse- Returns:
- parsed object
-
getKey
protected CompositeSequence getKey(Collection<Reporter> newItem)
- Specified by:
getKeyin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
put
protected void put(CompositeSequence key, Collection<Reporter> value)
- Specified by:
putin classBasicLineMapParser<CompositeSequence,Collection<Reporter>>
-
-