[Bio] / FigWebServices / sigs.cgi Repository:
ViewVC logotype

Diff of /FigWebServices/sigs.cgi

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

revision 1.44, Tue Sep 19 19:29:59 2006 UTC revision 1.45, Mon Oct 2 03:06:10 2006 UTC
# Line 60  Line 60 
60      $fig_or_sprout = new FIG;      $fig_or_sprout = new FIG;
61      unshift @$html, "<TITLE>The SEED Signature Genes Page</TITLE>\n";      unshift @$html, "<TITLE>The SEED Signature Genes Page</TITLE>\n";
62  }  }
 my $bbhs = $cgi->param('bbhs');  
63    
64  my $qflag = 0;  # Initialize tracing.
65  my $tracing = $cgi->param('TRACE');  Tracer::CGITrace($cgi);
66  if ($tracing) {  
67      my $type = $cgi->param('TTYPE');  my $bbhs = $cgi->param('bbhs');
     TSetup($tracing, $type);  
     if ($type eq 'QUEUE') { $qflag = 1; }  
     Tracer::TraceParms($cgi);  
 }  
68    
69  my @tmp = grep { $_ =~ /^\d+\.\d+$/ } $cgi->param;  my @tmp = grep { $_ =~ /^\d+\.\d+$/ } $cgi->param;
70  my @set1 = grep { $cgi->param($_) eq "set1" } @tmp;  my @set1 = grep { $cgi->param($_) eq "set1" } @tmp;
# Line 110  Line 105 
105    
106      $col_hdrs = ["Given","Set 1","","Set 2","genome","Genus/Species"];      $col_hdrs = ["Given","Set 1","","Set 2","genome","Genus/Species"];
107      $tab = [];      $tab = [];
108        Trace("Retrieving genomes.") if T(2);
109      @orgs = $fig_or_sprout->genomes("complete");      @orgs = $fig_or_sprout->genomes("complete");
110        Trace("Processing genomes.") if T(2);
111      foreach $org (@orgs)      foreach $org (@orgs)
112      {      {
113          $full{$org} = $fig_or_sprout->genus_species($org);          $full{$org} = $fig_or_sprout->genus_species($org);
# Line 124  Line 119 
119                                 -nolabels => 1);                                 -nolabels => 1);
120      # We're going to create a navigation bar here that gets you automatically      # We're going to create a navigation bar here that gets you automatically
121      # to the first organism beginning with a specified letter.      # to the first organism beginning with a specified letter.
122        Trace("Creating navigation bar.") if T(2);
123      my $bar = $cgi->a({ name => "bar" },"");      my $bar = $cgi->a({ name => "bar" },"");
124      my $currLetter = "";      my $currLetter = "";
125      foreach $org (@orgs)      foreach $org (@orgs)
# Line 155  Line 151 
151      {      {
152          push(@$html,"<br>",$cgi->checkbox( -name => 'bbhs', -value => 1, -override => 1, -label => 'Use BBHs' ),"<br>");          push(@$html,"<br>",$cgi->checkbox( -name => 'bbhs', -value => 1, -override => 1, -label => 'Use BBHs' ),"<br>");
153      }      }
154        Trace("Creating main form.") if T(2);
155      push(@$html,$cgi->h3("Find Proteins from Given Organism that Discriminate Set 1 from Set 2"),      push(@$html,$cgi->h3("Find Proteins from Given Organism that Discriminate Set 1 from Set 2"),
156                  $cgi->br, "Similarity Cutoff: ",$cgi->textfield(-name => "cutoff", -size => 10, -value => 1.0e-10),                  $cgi->br, "Similarity Cutoff: ",$cgi->textfield(-name => "cutoff", -size => 10, -value => 1.0e-10),
157                  $cgi->br,                  $cgi->br,
# Line 191  Line 188 
188      if (! $sim_cutoff) { $sim_cutoff = 1.0e-10 }      if (! $sim_cutoff) { $sim_cutoff = 1.0e-10 }
189      my @hits;      my @hits;
190      if ($mode == 2) {      if ($mode == 2) {
191            Trace("Computing discriminants.") if T(2);
192          @hits = &differentiating_genes(\@set1,\@set2,$given,$sim_cutoff,$is_sprout,$bbhs);          @hits = &differentiating_genes(\@set1,\@set2,$given,$sim_cutoff,$is_sprout,$bbhs);
193          Trace(scalar(@hits) . " hits found by differentiating_genes.") if T(3);          Trace(scalar(@hits) . " hits found by differentiating_genes.") if T(3);
194          if ($cgi->param('sort_by_func')) {          if ($cgi->param('sort_by_func')) {
# Line 257  Line 255 
255  if ($is_sprout) {  if ($is_sprout) {
256      # For sprout, we use a template.      # For sprout, we use a template.
257      my $template = "$FIG_Config::template_url/Sigs_tmpl.php";      my $template = "$FIG_Config::template_url/Sigs_tmpl.php";
258      my $traceList = ($qflag ? QTrace("html") : "");      my $traceList = QTrace("html");
259      my $result = PageBuilder::Build($template, { data => join("\n", @$html),      my $result = PageBuilder::Build($template, { data => join("\n", @$html),
260                                                   tracing => $traceList }, "Html");                                                   tracing => $traceList }, "Html");
261      print "CONTENT-TYPE: text/html\n\n";      print "CONTENT-TYPE: text/html\n\n";
262      print $result;      print $result;
263  } else {  } else {
264      # For SEED, a normal SEED page.      # For SEED, a normal SEED page.
265        push @$html, QTrace("html");
266      &HTML::show_page($cgi,$html);      &HTML::show_page($cgi,$html);
267  }  }
268    

Legend:
Removed from v.1.44  
changed lines
  Added in v.1.45

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3