[Bio] / FigKernelScripts / relevant_pchsG.pl Repository:
ViewVC logotype

Diff of /FigKernelScripts/relevant_pchsG.pl

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

revision 1.1, Sat May 7 20:57:47 2005 UTC revision 1.2, Sun May 29 02:15:42 2005 UTC
# Line 12  Line 12 
12   )   )
13      || die $usage;      || die $usage;
14    
15  if (($res = $dbh->SQL("SELECT r1.peg1,r1.peg2,r2.peg2,r3.peg2, r2.iden, r3.iden, r2.paraN, r3.paraN  my $qry = qq(SELECT r1.g1, r1.p1,
16                     r1.g2, r1.p2,
17                     r2.g2, r2.p2,
18                     r3.g2, r3.p2,
19                     r2.iden, r3.iden, r2.paraN, r3.paraN
20                         FROM close_pegs r1, condensed_sims r2, condensed_sims r3, close_pegs r4                         FROM close_pegs r1, condensed_sims r2, condensed_sims r3, close_pegs r4
21                         WHERE r1.peg1 LIKE 'fig|$genome%' AND               WHERE (r1.g1 = $genome AND
22                               r1.peg1 = r2.peg1 AND                      r1.g1 = r2.g1 AND
23                               r1.peg2 = r3.peg1 AND                      r1.p1 = r2.p1 AND
24                               r4.peg1 = r2.peg2 AND  
25                               r4.peg2 = r3.peg2")) &&                      r1.g2 = r3.g1 AND
26                        r1.p2 = r3.p1 AND
27    
28                        r4.g1 = r2.g2 AND
29                        r4.p1 = r2.p2 AND
30    
31                        r4.g2 = r3.g2 AND
32                        r4.p2 = r3.p2)
33                 );
34    
35    if (($res = $dbh->SQL($qry)) &&
36      (@$res > 0))      (@$res > 0))
37  {  {
38      foreach $x (sort { ($a->[0] cmp $b->[0]) or ($a->[1] cmp $b->[1]) or ($b->[4] <=> $a->[4]) }  @$res)      foreach $x (sort { ($a->[0] <=> $b->[0]) or ($a->[1] <=> $b->[1]) or ($a->[2] <=> $b->[2]) or
39                               ($a->[3] <=> $b->[3]) or ($b->[8] <=> $a->[8]) }  @$res)
40      {      {
41          print join("\t",@$x),"\n";          print join("\t",@$x),"\n";
42      }      }

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

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3