in reply to Searching and Coutning using 2 files with multiple columns
Something like golf
#!/usr/bin/perl -lan BEGIN { die "Usage: $0 Boundary.out DB.out" unless @ARGV == 2; } if ( $isDB ) { print $_, "\t" . grep { $_->[0] > $F[2] && $_->[1] < $F[3] } @{$chr{$F[1]}} } else { push @{$chr{$F[0]}}, [ @F[1, 2] ]; $isDB = eof; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Searching and Coutning using 2 files with multiple columns
by shart3 (Novice) on Sep 16, 2009 at 17:54 UTC | |
by ccn (Vicar) on Sep 16, 2009 at 18:51 UTC | |
by shart3 (Novice) on Sep 17, 2009 at 15:27 UTC | |
by ccn (Vicar) on Sep 17, 2009 at 17:48 UTC |
In Section
Seekers of Perl Wisdom