pdotcdot has asked for the wisdom of the Perl Monks concerning the following question:
so far i have used the following, but it still only matches 1 line at a time! ie when i use the the array seqs later each $i element is only 1 line. i am out of books/ideas so all help would be appreciate.*header abcdefghik sdsaadsd addds *header a....
many thanks in advance, i know this is novice question :-) PCwhile ($file=<INPUT1>){ chomp $line; if($file =~/^[a-z](.*?)(?=(\z))/msg){ $seq=$1; $seq=~ s/\n//; push @seqs, $seq; print OUTFILE2 @seqs; exit; } elsif($file =~/*/){ $header =$fastafile; chomp $header; $header=~s/>//; push @headers, $header; print OUTFILE "$header\n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: multi-line match
by broquaint (Abbot) on Aug 05, 2003 at 15:45 UTC | |
|
Re: multi-line match
by BrowserUk (Patriarch) on Aug 05, 2003 at 16:14 UTC | |
|
Re: multi-line match
by JamesNC (Chaplain) on Aug 05, 2003 at 17:02 UTC | |
|
Re: multi-line match
by pdotcdot (Acolyte) on Aug 06, 2003 at 14:22 UTC | |
|
Re: multi-line match
by pdotcdot (Acolyte) on Aug 07, 2003 at 10:01 UTC | |
by BrowserUk (Patriarch) on Aug 07, 2003 at 11:23 UTC | |
by pdotcdot (Acolyte) on Aug 08, 2003 at 09:33 UTC |