view rapsodyn/fastaGroomerForMakeBlastdb.pl @ 28:fefe6d89dbf1 draft

Uploaded
author mcharles
date Wed, 10 Sep 2014 08:10:38 -0400
parents afaf2e8aedcc
children 7b8646f46010
line wrap: on
line source

#!/usr/bin/perl
my $inputfasta = $ARGV[0];

open(IB, $inputfasta) or die ("Can't open $inputfasta \n");

while (my $ligne = <IB>){
	if ($ligne=~/\[.*?\=.*?\]/){
		$ligne =~ s/[\[\]]//g;
		print $ligne;
	}
	elsif ($ligne =~/^\>/){
		print $ligne;
		$ligne = <IB>;
		$ligne =~ s/N/a/g;
		print $ligne;
	}
	else {
		print $ligne;
	}
}

close (IB);