in reply to Re: How to get non-redundant DNA sequences from a FASTA file?
in thread How to get non-redundant DNA sequences from a FASTA file?

Hi biohisham,

I am trying to use your solution for redundant fasta file but Ive got this message:Global symbol "%hash" requires explicit package name at redundant.fasta line 14.

Global symbol "%hash" requires explicit package name at redundant.fast +a line 18. Global symbol "%hash" requires explicit package name at redundant.fast +a line 19. Global symbol "%hash" requires explicit package name at redundant.fast +a line 20. Global symbol "%hash" requires explicit package name at redundant.fast +a line 21.
I installed BioPerl: cpan>install CJFIELDS/BioPerl-1.6.924.tar.gz Data-Dumper: cpan>SMUELLER/Data-Dumper-2.154.tar.gz and also EDWARDSON/Data-Dumper-Hash-0.001.tar.gz

I really appreciate your answer about how to solve it. Btw, I am newbie. Thanks Eric

Replies are listed 'Best First'.
Re^3: How to get non-redundant DNA sequences from a FASTA file?
by Not_a_Number (Prior) on Sep 06, 2015 at 12:32 UTC

    You (and biohisham) need to declare %hash before using it. Simply put this line:

    my %hash;

    before the first while loop.

      Hi Not_a_Number, Many thanks for your suggestion. Now the script is working nicely. Regards.