[Bio] / Sprout / SubsystemSaplingLoader.pm Repository:
ViewVC logotype

Diff of /Sprout/SubsystemSaplingLoader.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1, Mon Jan 19 21:43:05 2009 UTC revision 1.2, Thu Feb 5 07:26:14 2009 UTC
# Line 186  Line 186 
186          }          }
187          # Next come the variants. Variant data is sparse in the SEED. We          # Next come the variants. Variant data is sparse in the SEED. We
188          # start by getting all the known variant codes.          # start by getting all the known variant codes.
189          my %variants = map { $self->Starless($_) => '' } $ssData->get_variant_codes();          my %variants = map { BaseSaplingLoader::Starless($_) => '' } $ssData->get_variant_codes();
190          # -1 and 0 are always present.          # -1 and 0 are always present.
191          $variants{'0'} = 'Subsystem functionality is incomplete.';          $variants{'0'} = 'Subsystem functionality is incomplete.';
192          $variants{'-1'} = 'Subsystem is not functional.';          $variants{'-1'} = 'Subsystem is not functional.';
193          # Now get notes from any variants that have them.          # Now get notes from any variants that have them. Note that we need
194            # to clean up the variant code with a call to Starless.
195          my $variantHash = $ssData->get_variants();          my $variantHash = $ssData->get_variants();
196          for my $variant (keys %$variantHash) {          for my $variant (keys %$variantHash) {
197              $variants{$variant} = $variantHash->{$variant};              my $realVariantID = BaseSaplingLoader::Starless($variant);
198                $variants{$realVariantID} = $variantHash->{$variant};
199          }          }
200          # Create the variants.          # Create the variants.
201          for my $variant (keys %variants) {          for my $variant (keys %variants) {
# Line 271  Line 273 
273          # curated.          # curated.
274          my $curated = ($raw_variant_code =~ /^\s*\*/ ? 0 : 1);          my $curated = ($raw_variant_code =~ /^\s*\*/ ? 0 : 1);
275          # Clear any waste from the variant code.          # Clear any waste from the variant code.
276          my $variant_code = $self->Starless($raw_variant_code);          my $variant_code = BaseSaplingLoader::Starless($raw_variant_code);
277          # Compute its type.          # Compute its type.
278          my $variant_type = ($variant_code == 0 ? 'incomplete' :          my $variant_type = ($variant_code =~ /^0/ ? 'incomplete' :
279                              $variant_code < 0 ? 'vacant' : 'normal');                              $variant_code =~ /^-/ ? 'vacant' : 'normal');
280          # Create the variant and machine IDs.          # Create the variant and machine IDs.
281          my $variantID = "$subID:$variant_code";          my $variantID = "$subID:$variant_code";
282          my $machineID = "$variantID:$genomeID";          my $machineID = "$variantID:$genomeID";

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3