Re: parsing script removing some lines help please

2011-09-30 Thread Chris Charley
John W. Krahn wrote: Mariano Loza Coll wrote: Hi John, Hello, I'm trying to learn a little bit more of Perl everyday, and I was intrigued about your earlier suggestion in a thread. my $bad_chromosomes = qr/^(?:6|8|14|16|18|Y)\t/; while (<$IN> ) { print $OUT $_ if !/$bad_chromosomes/

Re: parsing script removing some lines help please

2011-09-30 Thread John W. Krahn
Mariano Loza Coll wrote: Hi John, Hello, I'm trying to learn a little bit more of Perl everyday, and I was intrigued about your earlier suggestion in a thread. my $bad_chromosomes = qr/^(?:6|8|14|16|18|Y)\t/; while (<$IN> ) { print $OUT $_ if !/$bad_chromosomes/; } I get the s

Re: parsing script removing some lines help please

2011-09-30 Thread John W. Krahn
Nathalie Conte wrote: Hi, Hello, I am lost in my script, and would need to basic help please. I have got a file , separated by tabs, and the first column contain a chromosome number, then several other column with different infos. Basically I am trying to created a script that would take a f

RE: parsing script removing some lines help please

2011-09-30 Thread Ken Slater
> From: Nathalie Conte [mailto:n...@sanger.ac.uk] > Sent: Friday, September 30, 2011 9:38 AM > To: beginners@perl.org > Subject: parsing script removing some lines help please > > > > Hi, > I am lost in my script, and would need to basic help please. > I have got a

Re: parsing script removing some lines help please

2011-09-30 Thread John SJ Anderson
On Fri, Sep 30, 2011 at 09:37, Nathalie Conte wrote: > thanks for any clues It's a simple one, really.. 8^) > #!/software/bin/perl > use warnings; > use strict; > open(IN, " open(OUT, ">>removed.txt") or die( $! ); ObCorrectness: you should say something more like open( my $IN , '<' , 'example

parsing script removing some lines help please

2011-09-30 Thread Nathalie Conte
Hi, I am lost in my script, and would need to basic help please. I have got a file , separated by tabs, and the first column contain a chromosome number, then several other column with different infos. Basically I am trying to created a script that would take a file(see example), parse line b