Mercurial > repos > biomonika > linkyx
view scripts/get_sequences_based_on_ids.pl @ 2:0d8315be76b7
Uploaded
author | biomonika |
---|---|
date | Tue, 17 Feb 2015 21:59:51 -0500 |
parents | 05c27700e5ca |
children |
line wrap: on
line source
use Bio::DB::Fasta; my $fastaFile = shift; my $queryFile = shift; my $db = Bio::DB::Fasta->new( $fastaFile ); open (IN, $queryFile); while (<IN>){ chomp; $seq = $_; my $sequence = $db->seq($seq); if (!defined( $sequence )) { die "Sequence $seq not found. \n" } print ">$seq\n", "$sequence\n"; }