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

Diff of /FigWebServices/protein.cgi

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

revision 1.103, Mon Mar 21 22:01:22 2005 UTC revision 1.104, Fri Apr 8 18:36:29 2005 UTC
# Line 329  Line 329 
329      my $loc;      my $loc;
330    
331      my $user = $cgi->param('user');      my $user = $cgi->param('user');
332        my $org     = &genome_of($peg);
333        my $domain  = $fig_or_sprout->genome_domain($org);
334    
335        #...set default minimum size for euk or non-euk display region...
336        my $half_sz = ($domain =~ m/^euk/i) ? 50000 : 5000;
337    
     my $half_sz = 5000;  
338      my $fc = $cgi->param('fc');      my $fc = $cgi->param('fc');
339      my @fc_data;      my @fc_data;
340      if ($fc) {      if ($fc) {
# Line 349  Line 353 
353    
354      if ($loc = &feature_locationS($fig_or_sprout,$peg)) {      if ($loc = &feature_locationS($fig_or_sprout,$peg)) {
355          my($contig,$beg,$end) = &boundaries_of($fig_or_sprout,$loc);          my($contig,$beg,$end) = &boundaries_of($fig_or_sprout,$loc);
356    
357            my $len  = abs($end-$beg) + 1;
358            $half_sz = $half_sz * (1 + 3*int($len/$half_sz));   #...set scale of region...
359    #       print STDERR "half_sz = $half_sz\n";
360    
361          my $min = &max(0,&min($beg,$end) - $half_sz);          my $min = &max(0,&min($beg,$end) - $half_sz);
362          my $max = &max($beg,$end) + $half_sz;          my $max = &max($beg,$end) + $half_sz;
363          Trace("display_peg: min=$min max=$max beg=$beg end=$end") if T(2);          Trace("display_peg: min=$min max=$max beg=$beg end=$end") if T(2);
364    
365          my($feat,$min,$max) = &genes_in_region($fig_or_sprout,$cgi,&genome_of($peg),$contig,$min,$max);          my($feat,$min,$max) = &genes_in_region($fig_or_sprout,$cgi,&genome_of($peg),$contig,$min,$max);
366          Trace("beg=$beg end=$end New min = $min, max = $max, features = " . join(", ", @{$feat})) if T(3);          Trace("beg=$beg end=$end New min = $min, max = $max, features = " . join(", ", @{$feat})) if T(3);
367    
# Line 1790  Line 1800 
1800                          $aliases]);                          $aliases]);
1801          }          }
1802      }      }
1803      push(@$html,&HTML::make_table($col_hdrs,$tab,"Context on contig $contig1"));      push(@$html,&HTML::make_table($col_hdrs,$tab,"Context on contig $contig1 from base $beg to $end (".(abs($end-$beg)+1)." bp)"));
1804      push(@$html,$cgi->br,$cgi->submit('pin with checked genes'),$cgi->end_form,$cgi->br);      push(@$html,$cgi->br,$cgi->submit('pin with checked genes'),$cgi->end_form,$cgi->br);
1805      return ($beg,$end,$genes);      return ($beg,$end,$genes);
1806  }  }

Legend:
Removed from v.1.103  
changed lines
  Added in v.1.104

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3