Dear monks , I have written a script which selects the data till the line matches ======== then take that data in an array and execute a system command. The command has a default ouputfile in which the analysis is done and written. But my script overwrites the earlier data. Means the code is correct only thing is that I am overwriting the data in the ouput file which is being generated by the software which I am using by system command . How I can avoid that .
#!/usr/bin/perl -w use strict; my @aln; open(FILE,"vik.fna"); while (my $line = <FILE>) { if ($line !~ /^==========/) { push (@aln, $line); } else { open (SEQFILE, ">vik.tmp"); print SEQFILE join("",@aln); close SEQFILE; @aln = (); system("java -jar BMGE.jar -i vik.tmp -t AA -o tmsa.out") +; } }
In reply to using the system command by viktor
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |