Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Allow extensions on any terms, not just GO terms

  • Loading branch information...
commit 46b4bd18f8f4123cd446ab842bf9e6159dbff32d 1 parent e69359e
@kimrutherford authored
View
1  data/chromosome1.contig.embl
@@ -304,6 +304,7 @@ FT coiled-coil; qualifier=region; cv=sequence_feature;
FT date=20060605"
FT /controlled_curation="term=gene expression, alternative
FT transcripts; db_xref=PMID:11376151; cv=gene_ex;
+FT annotation_extension=has_downstream_target(GeneDB_Spombe:SPAC977.10)|has_downstream_target(GeneDB_Spombe:SPBC409.20c);
FT date=20060605"
FT /controlled_curation="term=species distribution, sequence
FT orphan; date=19700101"
View
8 lib/PomBase/Chado/CheckLoad.pm
@@ -111,7 +111,7 @@ method check
my $gene = $gene_rs->search({ uniquename => 'SPAC1556.06' })->next();
should ($gene->uniquename(), "SPAC1556.06");
- should ($gene->feature_cvterms()->count(), 11);
+ should ($gene->feature_cvterms()->count(), 12);
my $transcript = $chado->resultset('Sequence::Feature')
->find({ uniquename => 'SPAC977.10.1'});
@@ -139,7 +139,7 @@ method check
my $coiled_coil_cvterm = $self->get_cvterm('sequence', 'coiled_coil');
my @all_feature_cvterm = $chado->resultset('Sequence::FeatureCvterm')->all();
- should(scalar(@all_feature_cvterm), 103);
+ should(scalar(@all_feature_cvterm), 104);
my $cvterm_property_type_cv =
$chado->resultset('Cv::Cv')->find({ name => 'cvterm_property_type' });
@@ -148,7 +148,7 @@ method check
my $an_ex_rel_props_rs = $chado->resultset('Cv::Cvtermprop')->search({
type_id => { -in => $cvtermprop_types_rs->get_column('cvterm_id')->as_query() } });
- should($an_ex_rel_props_rs->count(), 4);
+ should($an_ex_rel_props_rs->count(), 6);
my ($localizes_term) = grep { $_->cvterm()->name() =~ /cellular protein localization \[localizes\] SPAC167.03c/ } @all_feature_cvterm;
assert(defined $localizes_term);
@@ -180,7 +180,7 @@ method check
}
my @all_props = $chado->resultset('Sequence::FeatureCvtermprop')->all();
- should(scalar(@all_props), 203);
+ should(scalar(@all_props), 204);
my $feat_rs = $chado->resultset('Sequence::Feature');
should ($feat_rs->count(), 74);
View
24 lib/PomBase/Chado/QualifierLoad.pm
@@ -120,6 +120,18 @@ method get_and_check_date($sub_qual_map) {
# about mismatches
method add_term_to_gene($pombe_feature, $cv_name, $embl_term_name, $sub_qual_map,
$create_cvterm) {
+ my $extension = $sub_qual_map->{annotation_extension};
+ if (defined $extension && $extension =~ /\|/) {
+ # split into multiple annotations
+ for my $bit (split /\|/, $extension) {
+ my $qual_copy = { %$sub_qual_map };
+ $qual_copy->{annotation_extension} = $bit;
+ $self->add_term_to_gene($pombe_feature, $cv_name, $embl_term_name, $qual_copy, 0);
+ }
+
+ return;
+ }
+
$embl_term_name =~ s/\s+/ /g;
$embl_term_name = $embl_term_name->trim();
@@ -888,17 +900,7 @@ method process_one_go_qual($chado_object, $bioperl_feature, $qualifier) {
my $term = delete $qual_map{term};
try {
- my $extension = $qual_map{annotation_extension};
- if ($extension && $extension =~ /\|/) {
- # split into multiple annotations
- for my $bit (split /\|/, $extension) {
- my $qual_copy = { %qual_map };
- $qual_copy->{annotation_extension} = $bit;
- $self->add_term_to_gene($chado_object, $cv_name, $term, $qual_copy, 0);
- }
- } else {
- $self->add_term_to_gene($chado_object, $cv_name, $term, \%qual_map, 0);
- }
+ $self->add_term_to_gene($chado_object, $cv_name, $term, \%qual_map, 0);
} catch {
my $systematic_id = $chado_object->uniquename();
warn "$_: failed to load qualifier '$qualifier' from $systematic_id:\n";
Please sign in to comment.
Something went wrong with that request. Please try again.