3 # Converts a FASTA alignment of *sequences* to a concise file of the
4 # form alignX;seq name:seq where X is an incremental integer and seq is
5 # a comma seperated list of the sequence
9 if ( $ARGV[0] ) { open( IN, "<$ARGV[0]" ) or die($!); }
10 else { *IN = *STDIN; }
12 my ( $seq, @seqs, @title );
32 if ( @title != @seqs ) { die("non matching number of titles and sequences!\n"); }
34 foreach ( 0 .. $#title ) {
35 print "align" . ( $_ + 1 ) . ";$title[$_]:$seqs[$_]\n";