Question: Installing BioPerl and using Bio/SeqIO.pm
0
gravatar for ccpowell
3 months ago by
ccpowell0
ccpowell0 wrote:

Hi there,

I am trying to run, generate_gc.pl followed by, wigToBigWig (UCSC Genome Browser script), to determine GC content and TATA boxes:

generate_gc.pl is located at: https://gist.githubusercontent.com/andrewyatz/fe8f4478d9127696d90bc4804c292056/raw/02c400f0022fd593bebc7d74a8d53ade9823c182/generate_gc.pl

WigToBigWig at: http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64.v369/wigToBigWig

When I run the following command I get the following error:

$ perl generate_gc.pl 5 tomato.fa tomatoGC5.wig

Can't locate Bio/SeqIO.pm in @INC (you may need to install the Bio::SeqIO module) (@INC contains: /home/user/perl5/lib/perl5/5.26.1/x86_64-linux-gnu-thread-multi /home/user/perl5/lib/perl5/5.26.1 /home/user/perl5/lib/perl5/x86_64-linux-gnu-thread-multi /home/user/perl5/lib/perl5 /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /home/user/perl5/lib/perl5/5.26.0 /home/user/perl5/lib/perl5/5.26.0/x86_64-linux-gnu-thread-multi /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at generate_gc.pl line 5. BEGIN failed--compilation aborted at generate_gc.pl line 5.

Here is my PATH: PATH=/home/user/perl5/bin:/home/user/miniconda3/bin:/home/user/miniconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin

So it appears perl5 is in my path, perl works I run a basic perl script & I have also run:

cpanm Bio::Perl

However, I still get this error...

Is there a specific way to install or set my path to find Bio/SeqIO.pm? I don't believe I've installed it correctly. I think this is probably due to the improper installation of BioPerl but I cannot find any good documentation.

Anything helps! Thank you!!

ADD COMMENTlink written 3 months ago by ccpowell0
1
gravatar for Jean-Karim Heriche
3 months ago by
EMBL Heidelberg, Germany
Jean-Karim Heriche23k wrote:

Learn about how perl finds its modules. Hints: read about @INC and 'use lib ...'. To see where your modules live, do:

perl -e 'print qq(@INC)'

which should give what's printed in the error message.

ADD COMMENTlink modified 3 months ago • written 3 months ago by Jean-Karim Heriche23k

Thank you very much!

I feel so silly now...such is learning The initial cpanm installation command was incorrect. Looking through the $ perl -e 'print qq(@INC)' output helped. I realized I needed to look in the perl5 dir for the Bio dir. Once I was there I saw that SeqIO wasn't present and noticed I was using the incorrect cpanm command.

cpanm Bio::Perl ---> cnanm Bio::SeqIO

Cheers!

ADD REPLYlink written 3 months ago by ccpowell0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 704 users visited in the last hour