Trying to get a Parsimony (and likelihood) Ratchet protocol going I spent a couple hours trying to get PAUPRat working, including compiling an old compiler and finding old versions of libraries and editing Makefiles… then I found a newer Java program that does the same thing: PRAP2. The program includes the Likelihood ratchet protocol described above but not the Parsimony. Here are the settings for the Parsimony ratchet protocol, as described by Sikes et al., which are then replicated by PRAP2 into PAUP* blocks.
[!* ----- Parsimony Ratchet -----*]
[!* as in PAUPrat *]
[!* January, 2009 *]
Time;
Log File=paupratchet.log;
Set Increase=auto;
hs status=no nrep=1 swap=tbr start=stepwise addseq=random nchuck=1 chuckscore=1;
savetrees file=mydata.tre replace;
savetrees file=mydata.tmp replace;
[!* paupcmd: * * * * * * * * * * * * * *]
pset mstaxa=uncertain;
hsearch status=no start=1 swap=tbr multrees=no;
[!* rewtdcmd:* * * * * * * * * * * * * *]
[!* normcmd:* * * * * * * * * * * * * *]
savetrees file=mydata.tmp replace;
gettrees file=mydata.tre mode=7;
savetrees file=mydata.tre replace;
gettrees file=mydata.tmp mode=3 warntree=no;
Time;
[!* stopcmd: * * * * * * * * * * * * * *]
gettrees file=mydata.tre mode=3;
pscores all;
Time;
Log Stop;
[!* * * * * * * * * * * * * * * * *]
[!* -- THIS SEARCH IS COMPLETE -- *]
[!* A LOG FILE HAS BEEN WRITTEN *]
[!* AND ALL TREES HAVE BEEN SAVED *]
[!* IT IS OKAY TO QUIT PAUP *]
[!* * * * * * * * * * * * * * * * *]
Quit;
Update: PRAP2 has a built-in parsimony ratchet that is more cleanly written than this one, except I had to remove the command ‘dropmode=execute’ because PAUP* 4b10 wasn’t recognizing it. Using the pre-configured ratchet you can choose the number of runs to code automatically, but using a custom script you can’t. So here’s a bash shell script to automate the script above, after generating some number (here N=20) script files named ‘sequences.[1-N].nexus’.
for i in `jot 20 1 20`;
do
`paup sequences.$i.nexus`
`mv -f mydata.tmp mydata.$i.tmp`
`mv -f mydata.tre mydata.$i.tre`
`mv -f paupratchet.log paupratchet.$i.log`
done
Since the parsimony ratchets run quickly it is fine to do them all on one processor, but I’m starting the likelihood runs separately on each processor. This script will run them one at a time, but if you add ‘screen -S like.$i’ to the line before ‘/bin/paup…’ it should start up to 10 simultaneously in separate “screens“, assuming your nexus files are all in the same directory and named ratchet.like.[1-10].nexus
for i in `jot 10 1 10`;
do
`mkdir like$i`
`cp ratchet.like.$i.nexus ./like$i/`
cd like$i
`/bin/paup4b10-ppc-macosx -n ./ratchet.like.$i.nexus`
cd ..
done
Tags: linux · phylogeny · scienceNo Comments
0 responses so far ↓
There are no comments yet...add one by filling out the form below.