Biopieces.open(options[:stream_in], options[:stream_out]) do |input, output|
input.each_record do |record|
if record[:SEQ] and record[:SEQ].length >= options[:size]
- entry = Seq.new(record[:SEQ_NAME], record[:SEQ], record[:SCORES])
- entry.type = 'dna'
+ entry = Seq.new_bp(record)
+ entry.type = :dna
entry.shred(options[:size], options[:coverage]) do |subentry|
output.puts subentry.to_bp