Class: Fastq
- Inherits:
-
Object
- Object
- Fastq
- Defined in:
- lib/fastq.rb
Defined Under Namespace
Classes: Read
Instance Method Summary collapse
- #each_read ⇒ Object
- #get_read ⇒ Object
-
#initialize(file) ⇒ Fastq
constructor
A new instance of Fastq.
Constructor Details
#initialize(file) ⇒ Fastq
Returns a new instance of Fastq.
13 14 15 16 17 18 19 |
# File 'lib/fastq.rb', line 13 def initialize file if is_gzipped?(file) @io = IO.popen("zcat #{file}") else @io = File.open file end end |
Instance Method Details
#each_read ⇒ Object
21 22 23 24 25 |
# File 'lib/fastq.rb', line 21 def each_read while read = get_read yield read end end |