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

View of /FigKernelScripts/score_dfcs.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (download) (as text) (annotate)
Mon Dec 5 18:56:38 2005 UTC (14 years, 7 months ago) by olson
Branch: MAIN
CVS Tags: caBIG-05Apr06-00, caBIG-13Feb06-00
Changes since 1.1: +17 -0 lines
Add license words.

#!/usr/bin/env /Volumes/raid/FIGdisk.v4/env/mac/bin/perl
#
# Copyright (c) 2003-2006 University of Chicago and Fellowship
# for Interpretations of Genomes. All Rights Reserved.
#
# This file is part of the SEED Toolkit.
# 
# The SEED Toolkit is free software. You can redistribute
# it and/or modify it under the terms of the SEED Toolkit
# Public License. 
#
# You should have received a copy of the SEED Toolkit Public License
# along with this program; if not write to the University of Chicago
# at info@ci.uchicago.edu or the Fellowship for Interpretation of
# Genomes at veronika@thefig.info or download a copy from
# http://www.theseed.org/LICENSE.TXT.
#


BEGIN {
    @INC = qw(
              /Volumes/raid/FIGdisk.v4/dist/releases/dev/mac/lib
              /Volumes/raid/FIGdisk.v4/dist/releases/dev/mac/lib/FigKernelPackages
              /Volumes/raid/FIGdisk.v4/dist/dev/mac/lib
              /Volumes/raid/FIGdisk.v4/dist/dev/mac/lib/FigKernelPackages
              /Volumes/raid/FIGdisk.v4/env/mac/lib/perl5/5.8.7/darwin-2level
              /Volumes/raid/FIGdisk.v4/env/mac/lib/perl5/5.8.7
              /Volumes/raid/FIGdisk.v4/env/mac/lib/perl5/site_perl/5.8.7/darwin-2level
              /Volumes/raid/FIGdisk.v4/env/mac/lib/perl5/site_perl/5.8.7
              /Volumes/raid/FIGdisk.v4/env/mac/lib/perl5/site_perl
              .
              /Volumes/raid/FIGdisk.v4/config
 
);
}
use Data::Dumper;
use Carp;
use FIG_Config;
$ENV{'BLASTMAT'} = "/Volumes/raid/FIGdisk.v4/BLASTMAT";
$ENV{'FIG_HOME'} = "/Volumes/raid/FIGdisk.v4";
# end of tool_hdr
########################################################################

use FIG;
my $fig = new FIG;

my @fc_bins = (
	       [0.554,100],
	       [0.626,50],
	       [0.532,25],
	       [0.369,13],
	       [0.219,7],
	       [0.140,0]
	      );

while (defined($_ = <STDIN>))
{
    chop;
    ($peg1,$peg2,$fc) = split(/\t/,$_);
    $sc = &score_fc($fc,\@fc_bins);
    print join("\t",($peg1,$peg2,$sc,"","","",$fc,"")),"\n";
}
sub score_fc {
    my($fcsc,$bins) = @_;

    for ($i=0; ($i < @$bins) && ($fcsc < $bins->[$i]->[1]); $i++) {}
    return $bins->[$i]->[0];
}

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3