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

View of /FigKernelScripts/assign_to_hypo.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (download) (as text) (annotate)
Mon Dec 1 20:46:40 2003 UTC (16 years, 6 months ago) by efrank
Branch: MAIN
CVS Tags: V00-00-01, delong-01, delong-02, V00-00-00

Makefile:
	get it to work with the release tools

All the rest:
	had to rename foo to foo.pl so that makefiles could recognize
	perl source from, say, Makefiles and READMEs

use FIG;
my $fig = new FIG;

$usage = "usage: assign_to_hypo Genome [functions=FunctionFile] [Parms for auto_assign]";

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

if ($ARGV[0] =~ /^functions=(\S+)/)
{
    $functions_file = $1;
    %assigned = map { $_ =~ /^(\S+)\t(\S[^\t\n]+\S)/; $1 => $2 } `cat $functions_file`;
    shift @ARGV;
    $use_file = 1;
}

open(TMP,">/tmp/tmp$$.fids") 
    || die "aborted";
foreach $fid ($fig->all_features($genome,"peg"))
{
    $func = $use_file ? $assigned{$fid} : scalar $fig->function_of($fid);
    if (&FIG::hypo($func))
    {
	print TMP "$fid\n";
    }
}
close(TMP);
$parms = join(" ",@ARGV);
&FIG::run("auto_assign $parms < /tmp/tmp$$.fids | make_calls");
unlink("/tmp/tmp$$.fids");


MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3