1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
|
#!/usr/bin/env perl
print $ARGV[0]." ".$ARGV[1]." ".$ARGV[2]." ".$#ARGV."\n";
if($#ARGV < 0 || $#ARGV > 3)
{
print "ERROR: usage: \"perl bsBranchLengths.pl alignmentFileName treeFileName numberOfReplicates\"\n";
exit;
}
$alignment = $ARGV[0];
$tree = $ARGV[1];
$reps = $ARGV[2];
system("./raxmlHPC -f j -m GTRCAT -b 12345 -# ".$reps." -s ".$alignment." -n REPLICATES");
for($i = 0; $i < $reps; $i++)
{
system("./raxmlHPC -f e -m GTRGAMMA -t ".$tree." -s ".$alignment.".BS".$i." -n REP".$i);
}
$concat = "";
for($i = 0; $i < $reps; $i++)
{
$concat = $concat." RAxML_result.REP".$i." ";
}
system("cat ".$concat." > bsTrees");
|