Mercurial > repos > rogerngo > iassembler
view iAssembler_wrapper.pl @ 5:1d53d653adef draft default tip
iAssembler perl wrapper dependency
author | rogerngo |
---|---|
date | Wed, 16 May 2012 00:24:38 -0400 |
parents | 00edccfa662b |
children |
line wrap: on
line source
#!/usr/bin/perl # Wrapper script written by: Roger Ngo, Sam Min and Todd H. Oakley, UCSB use warnings; use strict; use Cwd; my $dir = getcwd(); my $iAssemblerBinPath = '/labdata/nfs/galaxy/pkgs/iAssembler'; my $iAssemblerToolPath = '/labdata/nfs/galaxy/galaxy-dist/tools/iAssembler'; #iAssembler_wrapper.pl -i $input -e $maxlength -h $minoverlap -p $minpercent ...example my $input=$ARGV[1]; my $maxlength=$ARGV[3]; my $minoverlap=$ARGV[5]; my $minpercent=$ARGV[7]; open my $file, '<', $iAssemblerToolPath."\/increment.txt"; my $increment = <$file>; $increment = int($increment); close $file; my $temp = $increment; open(UPDATE, '>'.$iAssemblerToolPath."\/increment.txt"); $increment = $increment + 1; print UPDATE $increment; close(UPDATE); qx/cp $input $iAssemblerBinPath\/input.$temp.fasta/; chdir($iAssemblerBinPath); qx/$iAssemblerBinPath\/iAssembler.pl -i input.$temp.fasta -e $maxlength -h $minoverlap -p $minpercent/; chdir("$dir"); qx/cp $iAssemblerBinPath\/input.$temp.fasta_output\/unigene_seq.fasta unigene_seq.fasta/; qx/rm -rf $iAssemblerBinPath\/input.$temp.*/;