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

View of /FigKernelScripts/relevant_pchsG.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (download) (as text) (annotate)
Sat May 7 20:57:47 2005 UTC (15 years, 1 month ago) by overbeek
Branch: MAIN
add routines for BigFC

use FIG;
my $fig = new FIG;

use DBrtns;
my $dbh = $fig->db_handle;

$usage = "usage: relevant_pchs Genome";

(
 ($genome = shift @ARGV)
 )
    || die $usage;

if (($res = $dbh->SQL("SELECT r1.peg1,r1.peg2,r2.peg2,r3.peg2, r2.iden, r3.iden, r2.paraN, r3.paraN
                       FROM close_pegs r1, condensed_sims r2, condensed_sims r3, close_pegs r4
                       WHERE r1.peg1 LIKE 'fig|$genome%' AND
                             r1.peg1 = r2.peg1 AND
                             r1.peg2 = r3.peg1 AND
                             r4.peg1 = r2.peg2 AND
                             r4.peg2 = r3.peg2")) && 
    (@$res > 0))
{
    foreach $x (sort { ($a->[0] cmp $b->[0]) or ($a->[1] cmp $b->[1]) or ($b->[4] <=> $a->[4]) }  @$res)
    {
	print join("\t",@$x),"\n";
    }
}

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3