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

View of /FigKernelScripts/FFB2_build_updated_FF.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (download) (as text) (annotate)
Thu Jun 10 19:31:05 2010 UTC (9 years, 6 months ago) by overbeek
Branch: MAIN
Changes since 1.5: +2 -0 lines
build Blast directory for FRs

########################################################################

use FIG;

my $usage = "usage: FFB2_build_updated_FF OldReleaseDir NewReleaseDir";

my($oldD,$newD);

(
 ($oldD = shift @ARGV) && (-d $oldD) &&
 ($newD = shift @ARGV)
)
    || die $usage;

my $sort_args = "-T $FIG_Config::temp -S 4G";

mkdir($newD,0777) || die "You have an existing $newD; remove it and try again";
&FIG::run("FFB2_update_FIGfams $newD/families.2c $newD/family.functions $oldD");
&FIG::run("FFB2_get_oligos $newD/families.2c $newD/family.functions 2> $newD/function.index |" .
	  "sort $sort_args | FFB2_usable_motifs $newD/Kmers");

&FIG::run("FFB2_get_prots $newD/ProtsByGenomeSet $newD/setI");
&FIG::run("FFB2_get_prot_gs_oligos $newD/ProtsByGenomeSet 12 | sort $sort_args | FFB2_usable_motifs $newD/PhyloSigs");
mkdir("$newD/Merged",0777) || die "could not make $newD/Merged: $!";
foreach my $i (7..12)
{
    mkdir("$newD/Merged/$i",0777) || die "could not make $newD/Merged/$i: $!";
    &FIG::run("FFB2_merge_oligos $newD/Kmers/$i/good.oligos $newD/PhyloSigs/$i/good.oligos > $newD/Merged/$i/merged.oligos");
}
&FIG::run("FFB2_load_oligo_index $newD/function.index $newD/FRI.db");
&FIG::run("FFB2_load_oligo_index $newD/setI $newD/setI.db");

foreach my $i (7..12)
{
    &FIG::run("FFB2_create_binary_kmers -s 4,2 $newD/Merged/$i/merged.oligos $newD/Merged/$i/table.binary");
}

&FIG::run("FFB2_run_tests $newD");
&FIG::run("FFB2_compare_tests $oldD $newD");
&FIG::run("build_prok_nonff_fasta $newD > $newD/extra_prok_seqs.fasta");
&FIG::run("formatdb -p T -i $newD/extra_prok_seqs.fasta");

&FIG::run("FFB2_make_FF_index $newD $newD/fam.func.index $newD/FamFuncBlastD");

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3