[Bio] / FigKernelScripts / compute_simple_scores.pl Repository:
ViewVC logotype

Annotation of /FigKernelScripts/compute_simple_scores.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (view) (download) (as text)

1 : overbeek 1.1
2 :     $usage = "usage: compute_simple_scores MinSc < filtered.pchs > scored";
3 :     ($minsc = shift @ARGV)
4 :     || die $usage;
5 :    
6 : overbeek 1.2 while (defined($_ = <STDIN>) && ($_ !~ /\t0$/)) {}
7 : overbeek 1.1 while ($_ && ($_ =~ /^(\S+\t\S+)/))
8 :     {
9 :     $curr = $1;
10 :     $n = 0;
11 :     while ($_ && ($_ =~ /^(\S+\t\S+)/) && ($1 eq $curr))
12 :     {
13 :     $n++;
14 : overbeek 1.2 while (defined($_ = <STDIN>) && ($_ !~ /\t0$/)) {}
15 : overbeek 1.1 }
16 :    
17 :     if ($n >= $minsc)
18 :     {
19 :     print "$curr\t$n\n";
20 :     }
21 :     }

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3