seq = Seq.new
seq.seq = primer
- seq.type = 'dna'
+ seq.type = :dna
seq.reverse!.complement!
descriptor ? seq.seq + descriptor : seq.seq
casts << {:long=>'forward_rc', :short=>'F', :type=>'string', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
casts << {:long=>'reverse', :short=>'r', :type=>'string', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
casts << {:long=>'reverse_rc', :short=>'R', :type=>'string', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
-casts << {:long=>'max_dist', :short=>'m', :type=>'uint', :mandatory=>true, :default=>5000, :allowed=>nil, :disallowed=>"0"}
+casts << {:long=>'max_dist', :short=>'m', :type=>'uint', :mandatory=>true, :default=>5000, :allowed=>nil, :disallowed=>"0"}
options = Biopieces.options_parse(ARGV, casts)
tmpdir = Biopieces.mktmpdir
infile = File.join(tmpdir, "in.fna")
if options[:forward_rc]
- options[:forward] = Seq.new("test", options[:forward_rc], 'dna').reverse.complement.seq
+ options[:forward] = Seq.new("test", options[:forward_rc], :dna).reverse.complement.seq
end
if options[:reverse_rc]
- options[:reverse] = Seq.new("test", options[:reverse_rc], 'dna').reverse.complement.seq
+ options[:reverse] = Seq.new("test", options[:reverse_rc], :dna).reverse.complement.seq
end
raise ArgumentError, "no adaptor specified" unless options[:forward] or options[:reverse]