[LON-CAPA-cvs] cvs: modules /gerd/harvesting prob_in_seq.pl
www
www at source.lon-capa.org
Wed Sep 7 22:19:37 EDT 2011
www Thu Sep 8 02:19:37 2011 EDT
Added files:
/modules/gerd/harvesting prob_in_seq.pl
Log:
List problems in assignments
Index: modules/gerd/harvesting/prob_in_seq.pl
+++ modules/gerd/harvesting/prob_in_seq.pl
use strict;
my %resids=();
open(IN,'resource.dat');
while (my $line=<IN>) {
my @entries=split(/\t/,$line);
$entries[4]=~s/^\/res\///;
$resids{$entries[4]}=$entries[0];
}
close(IN);
my %seqs=();
# my $i=0;
open(IN,'allenc.dat');
while (my $line=<IN>) {
# $i++;
# if ($i>3000) { last; }
my @entries=split(/\t/,$line);
$entries[6]=~s/\_\_\_(\d+)$//;
my $rid=$resids{$entries[4]};
my %current=();
foreach my $already (split(/\,/,$seqs{$entries[6]})) {
$current{$already}=1;
}
unless ($current{$rid}) {
$current{$rid}=1;
$seqs{$entries[6]}=join(',',sort {$a<=>$b} (keys(%current)));
}
}
close(IN);
foreach my $key (keys(%seqs)) {
$seqs{$key}=~s/^\,//;
print $key."\t".$seqs{$key}."\n";
}
More information about the LON-CAPA-cvs
mailing list