Skip to content
Snippets Groups Projects
Commit b97926ab authored by Arnaud Kerhornou's avatar Arnaud Kerhornou
Browse files

Updated SGD GO parsing code to get the GO annotations from SGD rather than GOA

parent ac650320
No related branches found
No related tags found
No related merge requests found
......@@ -34,14 +34,17 @@ sub run {
my $file = @{$files}[0];
my $file_desc = @{$files}[1];
print STDERR "GO file to parse, $file\n";
#
# Get the descriptions from the desc file.
#
print STDERR "getting filehandle for description file, $file_desc\n";
my $go_io = $self->get_filehandle($file_desc);
if ( !defined $go_io ) {
print STDERR "ERROR: Could not open $file_desc\n";
print STDERR "ERROR: Could not open description file, $file_desc\n";
return 1; # 1 error
}
......@@ -96,6 +99,12 @@ sub run {
my %fish;
my $fishset;
# Add mapping between GO and SGD identifiers
my %cerevisiae;
my $cerevisiae_set;
my $cerevisiae_miss = 0;
my $count = 0;
......@@ -208,6 +217,28 @@ sub run {
#print join (" ", "MGI" ,$mgi_to_uniprot{$array[1]}, $array[4], "\n");
}
}
# SGD GO code
elsif ($array[0] =~ /SGD/) {
if(!defined($cerevisiae_set)){
$cerevisiae_set = 1;
# Todo: Make sure we get this hash populated
%cerevisiae = %{$self->get_valid_codes("sgd",$species_id)};
print STDERR "Got " . keys (%cerevisiae) . " cerevisiae ids\n";
}
if($cerevisiae{$array[1]}){
$self->add_to_xrefs($cerevisiae{$array[1]},$array[4],'',$array[4],$go_to_desc{$array[4]} || '',$array[6],$source_id,$species_id);
$count++;
#print join (" ", "UniProt" ,$swiss{$array[1]}, $array[4], "\n");
}
else{
$cerevisiae_miss++;
}
}
elsif(!defined($wrongtype{$array[0]})){
print STDERR "WARNING: unknown type ".$array[0]."\n" if($verbose);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment