[BioRuby] Bioruby and jrubyc problem

xyz mitlox at op.pl
Fri Feb 5 11:19:43 UTC 2010


Hallo,
I installed Bioruby with

jruby setup.rb.

then I run this script with jruby
--------------
#!/usr/bin/env jruby
 
require 'bio'
 
# creating a Bio::Sequence::NA object containing ambiguous alphabets
ambiguous_seq = Bio::Sequence::NA.new("atgcyrwskmbdhvn")
 
# show the contents and class of the DNA sequence object
p ambiguous_seq              # => "atgcyrwskmbdhvn"
p ambiguous_seq.class        # => Bio::Sequence::NA
 
# convert the sequence to a Regexp object
p ambiguous_seq.to_re        # => 
/atgc[tc][ag][at][gc][tg][ac][tgc][atg][atc][agc][atgc]/
p ambiguous_seq.to_re.class  # => Regexp
 
# example to match an ambiguous sequence to the rigid sequence
att_or_atc = Bio::Sequence::NA.new("aty").to_re
puts "match" if att_or_atc.match(Bio::Sequence::NA.new("att"))
if Bio::Sequence::NA.new("atc") =~ att_or_atc
  puts "also match"
end
--------------

without any problems.

After this I run it with Java and I have got following problem:

jrubyc s01.rb an then java -cp /home/mitlox/jruby-1.4.0/lib/jruby.jar:. s01
Exception in thread "main" s01.rb:3:in `require': no such file to load 
-- bio (LoadError)
        from s01.rb:3
        ...internal jruby stack elided...
        from Kernel.require(s01.rb:3)
        from (unknown).(unknown)(:1)

What did I wrong?

Best regards,




More information about the BioRuby mailing list