more simple examples
example, run two PAUP jobs
Go to
paup directory and create another directory called
paup_2_standard. Copy the example data file "example_data.nex" (no PAUP batch block in it) to the new directory. There are two jobs. One is to get a NJ tree and the other is to get UPGMA tree. You have two ways to do that on condor. Similarly to the above, you can put the PAUP block in the data file or in a seperate file.
1) add PAUP batch block to the data file
File name puap_2_standard_nj.nex
#NEXUS
Begin data;
[No change in data block]
....
;
End;
begin paup;
set autoclose=yes warnreset=no increase=auto;
log file='paup_2_standard_nj.log' replace;
nj;
savetrees file='paup_2_standard_nj.tre' replace;
end;
download here paup_2_standard_nj.nex
File name puap_2_standard_upgma.nex
#NEXUS
Begin data;
[No change in data block]
....
;
End;
begin paup;
set autoclose=yes warnreset=no increase=auto;
log file='paup_2_standard_upgma.log' replace;
upgma;
savetrees file='paup_2_standard_upgma.tre' replace;
end;
download here paup_2_standard_upgma.nex
2) Your submit description file should be something like this (file name paup_2_standard_withpaupblock.submit)
####################################################
#
# example, run two PAUP jobs on condor standard universe
#
#####################################################
Universe = standard
Executable = /cluster/bin/condor_paupdev
Arguments = paup_2_standard_nj.nex -n
output = paup_2_standard_nj.output
error = paup_2_standard_nj.error
log = paup_2_standard_nj.log
Queue
Arguments = paup_2_standard_upgma.nex -n
output = paup_2_standard_upgma.output
error = paup_2_standard_upgma.error
log = paup_2_standard_upgma.log
Queue
download here paup_2_standard.submit
3) You can use
condor_q yourusername to check the stauts of your job. After it is finished, use
ls -l to check your files in your directory.
| [yanfeng@petal017 two_data_file]$ condor_q yanfeng |
-- Submitter: petal017.csit.fsu.edu : <144.174.160.147:10076> : petal017.csit.fsu.edu
ID OWNER SUBMITTED RUN_TIME ST PRI SIZE CMD
56900.0 yanfeng 5/26 16:38 0+00:00:08 R 0 1.8 condor_paupdev pau
56900.1 yanfeng 5/26 16:38 0+00:00:14 R 0 1.8 condor_paupdev pau
2 jobs; 0 idle, 2 running, 0 held
| [yanfeng@petal017 two_data_file]$ ls -l |
total 19
-rw-rw-r-- 1 yanfeng student 0 May 23 09:34 paup_2_standard_nj.error
-rw-rw-r-- 1 yanfeng student 1956 May 23 09:41 paup_2_standard_nj.log
-rwxrw-r-- 1 yanfeng student 2054 May 22 21:47 paup_2_standard_nj.nex
-rw-rw-r-- 1 yanfeng student 2081 May 23 09:41 paup_2_standard_nj.output
-rw-r--r-- 1 yanfeng student 452 May 23 09:41 paup_2_standard_nj.tre
-rw-rw-r-- 1 yanfeng student 587 May 22 21:48 paup_2_standard.submit
-rw-rw-r-- 1 yanfeng student 0 May 23 09:34 paup_2_standard_upgma.error
-rw-rw-r-- 1 yanfeng student 1973 May 23 09:41 paup_2_standard_upgma.log
-rwxrw-r-- 1 yanfeng student 2062 May 22 21:47 paup_2_standard_upgma.nex
-rw-rw-r-- 1 yanfeng student 2104 May 23 09:41 paup_2_standard_upgma.output
-rw-r--r-- 1 yanfeng student 442 May 23 09:41 paup_2_standard_upgma.tre

Tips
Here we give one output file, one error file and one log file for every queue. We also can give all queues onlu one shared output file, one shared error file and one shared log file. (Condor output file will be overwritten, but it is not very important for us. You can find your results in PAUP log files. The condor log files and error files will not be overwritten. They will record the processes of all your jobs.) Then the submit description file will like below (file name paup_2_standard_share.submit).
####################################################
#
# example, run two paup jobs on condor standard universe
# share output, error and log file
#
#####################################################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = paup_2_standard_nj_upgma.output
# record all queue outputs
error = paup_2_standard_nj_upgma.error
# record all queue errors
log = paup_2_standard_nj_upgma.log
# record all queue logs
Arguments = paup_2_standard_nj.nex -n
Queue
Arguments = paup_2_standard_upgma.nex -n
Queue
download here paup_2_standard_share.submit
Suppose you have two paup jobs. You want have same condor log file name, condor error file name, and condor output file name for them. Then you need to creat two directory (let us call it nj and upgma) with command "
mkdir nj upgma ". Move your data file there. with command "
mv paup_2_standard_nj.nex ./nj/ " and " mv
paup_2_standard_upgma.nex ./upgma/ ". Change your submit description file something like below.
( file name paup_2_std.submit)
########################################
#
# example, run two PAUP jobs on condor standard universe
#
#########################################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = paup_2_standard.output
# record nj or upgma queue output
error = paup_2_standard.error
# record nj or upgmaqueue error
log = paup_2_standard.log
# record nj or upgma queue log
InitialDir = ./nj
Arguments = paup_2_standard_nj.nex -n
Queue
InitialDir = ./upgma
Arguments = paup_2_standard_upgma.nex -n
Queue
download here paup_2_std.submit
7) more realistic examples
testing for homogeneity
The data includes five deer familay mitochondrial genomes. 12S, 16S, COX1, COX3 and CytB are always used as the molecuar marker for phylogenetic analysis. But can we combine them for analysis ? We can use PAUP to do "partition Homogeneity Test".
1)Data set with PAUP block.
File name 5deer.nex
#NEXUS
BEGIN DATA;
dimensions ntax=5 nchar=16684;
format missing=?
symbols="ABCDEFGHIKLMNPQRSTUVWXYZ"
interleave datatype=DNA gap= -;
matrix
M.crin GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.munt GTTAATGTAGCTTAAACAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.reev GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ce GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ye GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
........
;
end;
BEGIN SETS;
CHARSET 12S = 70-1028;
CHARSET 16S = 1098-2670;
CHARSET COX1 = 5339-6883;
CHARSET COX3 = 8625-9408;
CHARSET CYTB = 14167-15307;
TAXSET outgroup = C.n.ce C.n.ye;
CHARPARTITION 12S.16S = 12S:12S, 16S:16S;
CHARPARTITION 12S.COX1 = 12S:12S, COX1:COX1;
CHARPARTITION 12S.COX3 = 12S:12S, COX3:COX3;
CHARPARTITION 12S.CYTB = 12S:12S, CYTB:CYTB;
CHARPARTITION 16S.COX1 = 16S:16S, COX1:COX1;
CHARPARTITION 16S.COX3 = 16S:16S, COX3:COX3;
CHARPARTITION 16S.CYTB = 16S:16S, CYTB:CYTB;
CHARPARTITION COX1.COX3 = COX1:COX1, COX3:COX3;
CHARPARTITION COX1.CYTB = COX1:COX1, CYTB:CYTB;
CHARPARTITION COX3.CYTB = COX3:COX3, CYTB:CYTB;
CHARPARTITION ALLMARKER =12S:12S, 16S:16S, COX1:COX1, COX3:COX3, CYTB:CYTB;
END;
begin paup;
[execute 5deer.nex;]
set autoclose=yes warnreset=no increase=auto;
log file= 5deer.log append=yes;
exclude all;
include 12S 16S COX1 COX3 CYTB /only;
hompart partition=ALLMARKER nreps= 1000 seed = 123;
[test the total markers]
exclude all;
include 12S 16S /only;
hompart partition=12S.16S nreps= 1000 seed = 123;
hsearch;showtree;
[test marker pair, so does the below]
exclude all;
include 12S COX1 /only;
hompart partition=12S.COX1 nreps=1000 seed = 123 ;
hsearch;showtree;
exclude all;
include 12S COX3 /only;
hompart partition=12S.COX3 nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include 12S CYTB /only;
hompart partition=12S.CYTB nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include 16S COX1 /only;
hompart partition=16S.COX1 nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include 16S COX3 /only;
hompart partition=16S.COX3 nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include 16S CYTB /only;
hompart partition=16S.CYTB nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include COX1 COX3 /only;
hompart partition=COX1.COX3 nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include COX1 CYTB /only;
hompart partition=COX1.CYTB nreps=1000 seed = 123;
hsearch;showtree;
exclude all;
include COX3 CYTB /only;
hompart partition=COX3.CYTB nreps=1000 seed = 123;
hsearch;showtree;
end;
download here 5deer_pht.nex
2) The submit description file
file name 5deer_pht.submit.
###########
#
# example , run paup partition Homogeneity Test on condor standard
#
###########
Universe = standard
Executable = /cluster/bin/condor_paupdev
Arguments = 5deer_pht.nex -n
output = 5deer_pht.output
error = 5deer_pht.error
log = 5deer_pht.log
Queue
download here 5deer_pht.submit
3) Result
You can view the result file 5deer.log to find the result.
hompart partition=ALLMARKER p = 0.107
the p value between the five molecular markers.
16S COX1 COX3 CYTB
12S 1 1 0.311 1
16S 1 0.007 1
COX1 0.038 1
COX3 0.119
download here 5deer.log
4) Conclusion.
The null hypothesis(H0) is that the same tree underlies the different data sets and the alternative hypothesis(H1) is that different tree underlies the different data sets.
16S and COX3 have the p value 0.007 which is lower than 0.05. Then reject the null hypothesis. Consider other p values between different molecular markers, we will only conbine 12S, 16S, COX1 and CytB together to for analysis.
maximum Parsimony
1) Data set without PAUP block
File name 5deer.nex.
#NEXUS
BEGIN DATA;
dimensions ntax=5 nchar=16684;
format missing=?
symbols="ABCDEFGHIKLMNPQRSTUVWXYZ"
interleave datatype=DNA gap= -;
matrix
M.crin GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.munt GTTAATGTAGCTTAAACAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.reev GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ce GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ye GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
........
;
end;
BEGIN SETS;
CHARSET 12S = 70-1028;
CHARSET 16S = 1098-2670;
CHARSET COX1 = 5339-6883;
CHARSET COX3 = 8625-9408;
CHARSET CYTB = 14167-15307;
TAXSET outgroup = C.n.ce C.n.ye;
END;
download here 5deer_mp.nex
2) PAUP block
Maximum Parsimony using branch & bound
File name 5deer_mp_bb.nex
#nexus
begin paup;
[maximum parsimony using branch & bound]
execute 5deer.nex;
set autoclose=yes warnreset=no increase=auto;
Outgroup outgroup;
log file= 5deer_mp_bb.log replace ;
exclude all;
include 12S 16S COX1 CYTB /only;
set criterion = parsimony;
search = bandb;
savetrees file = 5deer_mp_bb.tre root brlens replace;
log stop;
end;
download here 5deer_mp_bb.nex
Maximum Parsimony using branch-swapping by TBR
File name 5deer_mp_swaptbr.nex)
#nexus
begin paup;
execute 5deer.nex;
set autoclose=yes warnreset=no increase=auto;
Outgroup outgroup;
log file= 5deer_mp_swaptbr.log replace ;
exclude all;
include 12S 16S COX1 CYTB /only;
set criterion = parsimony;
search= hsearch swap = tbr;
savetrees file = 5deer_mp_swaptbr.tre root brlens replace;
log stop;
end;
download here 5deer_mp_swaptbr.nex
Maximum Parsimony using branch-swapping by NNI
File name 5deer_mp_swapnni.nex
#nexus
begin paup;
execute 5deer.nex;
set autoclose=yes warnreset=no increase=auto;
Outgroup outgroup;
log file= 5deer_mp_swapnni.log replace ;
exclude all;
include 12S 16S COX1 CYTB /only;
set criterion = parsimony;
search= hsearch swap = nni;
savetrees file = 5deer_mp_swapnni.tre root brlens replace;
log stop;
end;
download here 5deer_mp_swapnni.nex
3) submit description file
File name 5deer_mp.submit
#####################
#
# use condor to Maximum parsimony using brach & bound
# and Maximum parsimony using brach -swapping by TBR
# and Maximum parsimony using brach -swapping by NNI
#
#####################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = 5deer_mp.output
error = 5deer_mp.error
log = 5deer_mp.log
#We can give one output file, one error file and one log file for all queues.
#We also can give evey queue one output file, one error file and one log file like the example above
Arguments = 5deer_mp_bb.nex -n
Queue
Arguments = 5deer_mp_swapnni.nex -n
Queue
Arguments = 5deer_mp_swaptbr.nex -n
Queue
download here 5deer_mp.submit
4) use
condor_q username ,
ls_l, and
cat command to check your result
total 120
-rw-r--r-- 1 yanfeng student 1718 May 23 11:35 5deer_mp_bb.log
-rwxrw-r-- 1 yanfeng student 351 May 23 11:04 5deer_mp_bb.nex
-rw-r--r-- 1 yanfeng student 1278 May 23 11:35 5deer_mp_bb.tre
-rw-rw-r-- 1 yanfeng student 0 May 23 11:28 5deer_mp.error
-rw-rw-r-- 1 yanfeng student 1907 May 23 11:36 5deer_mp.log
-rw-rw-r-- 1 yanfeng student 3061 May 23 11:36 5deer_mp.output
-rwxrw-r-- 1 yanfeng student 545 May 23 11:29 5deer_mp.submit
-rw-r--r-- 1 yanfeng student 1824 May 23 11:36 5deer_mp_swapnni.log
-rwxrw-r-- 1 yanfeng student 381 May 23 11:05 5deer_mp_swapnni.nex
-rw-r--r-- 1 yanfeng student 1457 May 23 11:36 5deer_mp_swapnni.tre
-rw-r--r-- 1 yanfeng student 1824 May 23 11:36 5deer_mp_swaptbr.log
-rwxrw-r-- 1 yanfeng student 381 May 23 11:05 5deer_mp_swaptbr.nex
-rw-r--r-- 1 yanfeng student 1457 May 23 11:36 5deer_mp_swaptbr.tre
-rwxrw-r-- 1 yanfeng student 101170 May 23 10:55 5deer.nex
maximum Likelihood
1) Dataset without PAUP block.
File name 5deer_ml.nex.
#NEXUS
BEGIN DATA;
dimensions ntax=5 nchar=16684;
format missing=?
symbols="ABCDEFGHIKLMNPQRSTUVWXYZ"
interleave datatype=DNA gap= -;
matrix
M.crin GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.munt GTTAATGTAGCTTAAACAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
M.reev GTTAATGTAGCTTAAGCAATAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ce GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
C.n.ye GTTAATGTAGCTTAAACAACAAAGCAAGGCACTGAAAATGCCTAGATGAG
........
;
end;
BEGIN SETS;
CHARSET 12S = 70-1028;
CHARSET 16S = 1098-2670;
CHARSET COX1 = 5339-6883;
CHARSET COX3 = 8625-9408;
CHARSET CYTB = 14167-15307;
TAXSET outgroup = C.n.ce C.n.ye;
END;
download here 5deer_ml.nex
2) paup blocks with different Maximum Likelihood tree reconstruction methods
a)
Maximum Likelihood tree reconstruction. MP-tree used to obtain parameter estimates, Branch-swap by NNI [GTR-G-I-NNI]
filename 5deer_ml_mp_gtrginni.nex
#nexus
begin paup;
execute 5deer_ml.nex;
set autoclose=yes warnreset=no increase=auto;
outgroup outgroup;
set criterion=parsimony;
hsearch swap=tbr;
set criterion=likelihood;
lset nst=6 rmatrix=estimate basefreq=empirical rates=gamma shape=estimate pinvar=estimate;
lscores 1;
lset rmatrix=prev shape=prev pinvar=prev;
hsearch start=1 swap=nni;
savetrees file=5deer_ml_mp_gtrginni.tre root brlens replace=yes;
end;
download here 5deer_ml_mp_gtrginni.nex
b)
Maximum Likelihood tree reconstruction. Initial tree obtained by random addition, Bra-swap by TBR [GTR-G-I-TBR]
File name 5deer_ml_ran_gtrgitbr.nex
#nexus
begin paup;
execute 5deer_ml.nex;
set autoclose=yes warnreset=no increase=auto;
outgroup outgroup;
set criterion=likelihood;
lset nst=6 rmatrix=estimate basefreq=empirical rates=gamma shape=estimate pinvar=estimate;
hsearch addseq=random nreps=10 swap=tbr;
savetrees file=5deer_ml_ran_gtrgitbr.tre root brlens append=yes;
end;
download here 5deer_ml_ran_gtrgitbr.nex
3) concor submit description
File name 5deer_ml.submit
############################
#
# Maximum Likelihood tree reconstruction
# one is to use MP-tree used to obtain parameter estimates, Branch-swap by NNI
# the other is to use initial tree obtained by random addition, Bra-swap by TBR
#
############################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = 5deer_ml.output
error = 5deer_ml.error
log = 5deer_ml.log
Arguments = 5deer_ml_mp_gtrginni.nex -n
Queue
Arguments = 5deer_ml_ran_gtrgitbr.nex -n
Queue
download here 5deer_ml.submit
4) use
condor_q username ,
ls_l , and
cat command to check your result
total 116
-rw-rw-r-- 1 yanfeng student 0 May 23 12:39 5deer_ml.error
-rw-rw-r-- 1 yanfeng student 1271 May 23 12:43 5deer_ml.log
-rw-rw-r-- 1 yanfeng student 449 May 23 12:38 5deer_ml_mp_gtrginni.nex
-rw-r--r-- 1 yanfeng student 2430 May 23 12:41 5deer_ml_mp_gtrginni.tre
-rwxrw-r-- 1 yanfeng student 101174 May 22 11:56 5deer_ml.nex
-rw-rw-r-- 1 yanfeng student 5910 May 23 12:43 5deer_ml.output
-rw-rw-r-- 1 yanfeng student 353 May 23 12:39 5deer_ml_ran_gtrgitbr.nex
-rw-r--r-- 1 yanfeng student 2371 May 23 12:43 5deer_ml_ran_gtrgitbr.tre
-rw-rw-r-- 1 yanfeng student 536 May 22 11:52 5deer_ml.submit
bootstrap search with RepMaker
RepMaker by Jim Wilgenbusch is a perl utility for automatically making multiple NEXUS files. Files can be used to distribute a single PAUP* bootstrap analysis over multiple machines using the scheduler Condor or the perl utility BsLauncher (included with RepMaker).Download RepMaker at
http://paup.csit.fsu.edu/scripts/RepMaker.tar.gz
Unzip it and you can find good documetation files. Here we simplly paste the quickstart.
For the impatient:
1. edit the input.nex file
2. run RepMaker
> repmaker
(Fellow the instruction.)
3.
> cd RepFiles
4.
> condor_submit repMaker.cmd
(After all runs complete)
5.
> ./getTrees.pl
Let us do some pratics on our data.
1) download the RepMaker and unzip it. Copy the"host.in" and "repmaker" file to your data file directory. Edit the input.nex file. The input.nex file contains a paup block with all the paup commands
that will be executed for each bootstrap replicate.
Data file is the same as the Maximum Likelihood example. You can
download here 5deer_rep.nex .
#nexus
[You can omit #nexus here because this file will be modified by repmaker and #nexus will be added at the beginning]
begin paup;
[maximum parsimony using branch-swapping by NNI]
execute 5deer_rep.nex; [You can omit it. repmaker will add it later]
set autoclose=yes warnreset=no increase=auto;
Outgroup outgroup;
log file= 5deer_mp_swapnni.log replace ;
exclude all;
include 12S 16S COX1 CYTB /only;
set criterion = parsimony;
search = hsearch swap = nni; [Do not include "bootstrap nreps =100". It will run by RepMaker"]
savetrees file = 5deer_mp_swapnni.tre root brlens replace;
log stop;
end;
download here input.nex
2) run RepMaker
| [yanfeng@petal017 pm]$ repmaker |
Then input your data file name "5deer_rep.nex".
or
| [yanfeng@petal017 pm]$ repmaker 5deer_rep.nex |
How many bootstrap replicates do you want to run?
Divided into how many pieces?
Do you want to specify a fixed bootstrap seed for each piece? <y|N>
If you type "Yes" the number used for the bseed option in the PAUP
block will correspond to the piece.
Add specific hsearch options for each bootstrap replicate.
Do not include a "/" or a ";".
For example type: addseq=random nreps=5 RearrLimit=500
To use the PAUP defaults, hit return.
return
Add additional bootstrap options here.
To use the PAUP defaults, hit return.
return
Do you want PAUP to keep a log file for each bootstrap replicate? <Y|n>
Pick a Condor "universe": <standard(S)|vanilla(v)>
Do you want to be notified by email when your job(s) complete? <y|N>
Choose notification level (see man condor_submit for details):
<complete(C)|error(e)|never(n)|always(a)>
What is your email address?
After that it will show some instruction and then return Unix prompt.
3 )
You will see a directory named "RepFiles".
4.
You will see "rep.0 rep.1 ...... rep.99 5deer.nex getTree.pl repMaker.cmd". Then repMaker.cmd is the submit descripition file.
You can use
cat fileName command to view the content of the those files.
# paup running in Condor standard Universe
initialdir = /a/fs/u5/users/yanfeng/condor_dir/paup/realisticExamples/5_deer/rep/RepFiles
Rank = kflops
Executable = /cluster/bin/condor_paupdev
Universe = standard
requirements = OpSys =="LINUX" && Arch =="INTEL"
notification = always
notify_user = yanfeng@csit.fsu.edu
arguments = rep.$(Process) -n -f
output = rep_out.$(Process)
error = rep_error.$(Process)
log = rep.log
Queue 10
| > condor_submit repMaker.cmd |
This will submit your job to condor to do 10 bootstrapping at 10 nodes of condor. (For practice, we just use 10 bootstrapping. For your real data, you can use 1000 bootstrapping or other number)
Submitting job(s)..........
Logging submit event(s)..........
10 job(s) submitted to cluster 56793.
You can also use
condor_q username command to view the status of your job and other commands to manage your jobs.
5)
After all runs complete. You will the below files
5deer_mp_swapnni.log rep.7 rep_bstrees.9 rep_log.0 rep_out.1
5deer_mp_swapnni.tre rep.8 rep_error.0 rep_log.1 rep_out.2
5deer_rep.nex rep.9 rep_error.1 rep_log.2 rep_out.3
getTrees.nex rep_bstrees.0 rep_error.2 rep_log.3 rep_out.4
getTrees.pl rep_bstrees.1 rep_error.3 rep_log.4 rep_out.5
rep.0 rep_bstrees.2 rep_error.4 rep_log.5 rep_out.6
rep.1 rep_bstrees.3 rep_error.5 rep_log.6 rep_out.7
rep.2 rep_bstrees.4 rep_error.6 rep_log.7 rep_out.8
rep.3 rep_bstrees.5 rep_error.7 rep_log.8 rep_out.9
rep.4 rep_bstrees.6 rep_error.8 rep_log.9
rep.5 rep_bstrees.7 rep_error.9 repMaker.cmd
rep.6 rep_bstrees.8 rep.log rep_out.0
You can use
getTrees.pl to get the consensus tree.
>
./getTrees.pl
The getTrees.pl script will concatenate all of the individual bootstrap tree files and
get paup to save the consensus treefile to repMakerBS.tre.
If you want to transfer things to your Mac or PC so that you can print a pretty picture,
move the following files:
allReps.out
getTrees.nex
YourDataFile.nex (5deer_rep.nex]
The getTrees.nex file will have to be changed to reflect the location of your
data file on your Mac or PC. The getTrees.nex file will look something like this:
begin paup;
execute ~/condor_dir/paup/realisticExamples/5_deer/rep/5deer_rep.nex;
[<---- !!!! CHANGE THIS LINE !!!!!]
gettrees allblocks=yes StoreTreeWts=yes file=allReps.out mode=3;
contree all/strict=no majrule=yes usetreewts=yes treefile = repMakerBS.tre;
end;
You can run it on non-condor version paup with command
paup getTrees.nex
After PAUP finishes, you will find the consensus tree file repMakerBS.tre.
model test
1) data set and paup block
Data file is the same as the Maximum Likelihood example. You can
download here 5deer_model.nex .
model test PAUP block
file name 5deer_testmodel.nex
#NEXUS
[! ***** MODELFIT BLOCK -- MODELTEST 3.4 *****]
[The following command will calculate a NJ tree using the JC69 model of evolution]
BEGIN PAUP;
execute 5deer_model.nex;
log file= modelfit.log replace;
DSet distance=JC objective=ME base=equal rates=equal pinv=0
subst=all negbrlen=setzero;
NJ showtree=no breakties=random;
End;
[!
***** BEGIN TESTING 56 MODELS OF EVOLUTION ***** ]
BEGIN PAUP;
execute 5deer.nex;
Default lscores longfmt=yes;
Set criterion=like;
[!
** Model 1 of 56 * Calculating JC **]
lscores 1/ nst=1 base=equal rates=equal pinv=0
scorefile=model.scores replace;
[!
** Model 2 of 56 * Calculating JC+I **]
lscores 1/ nst=1 base=equal rates=equal pinv=est
scorefile=model.scores append;
.....
[!
** Model 56 of 56 * Calculating GTR+I+G **]
lscores 1/ nst=6 base=est rmat=est rates=gamma shape=est pinv=est
scorefile=model.scores append;
LOG STOP;
END;
download here 5deer_testmodel.nex .
2) condor submit description file
File name 5deer_testmodel.submit
#################
#
# model test (substitution model comparison)
#
#################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = modeltestpaupblock.output
error = modeltestpaupblock.error
log = modeltestpaupblock.log
Arguments = modeltestpaupblock.nex -n
Queue
download here 5deer_testmodel.submit
3) After the job completed, you will find a file named "model.scores".
Then download the
modeltest soft developed by David Posada. Then use window DOS command "
Modeltest3.6.exe < model.scores > test.outfile " to get the analysis report. (For instruction details, please refer to
running Modeltest on Windows. By Bevan Weir ). Open up test.outfile in notepad. This file explains which model is the best. In this file, there are two criteria, likelihood ratio test and the AIC criterion. When the two criteria choose different models, we prefer to use the likelihood ratio test result. Copy the parameters from the file (found between the BEGIN PAUP; and END; commands). Add this to into your paup block.
Below is an example of paup block (file name 5deer_ml_bestmodel.nex)
#nexus;
BEGIN PAUP;
set autoclose=yes warnreset=no increase=auto;
execute 5deer_model.nex;
set criterion=likelihood;
log file=5deer_ml_bestmodel.log;
Lset Base=(0.3342 0.2443 0.1336) Nst=6 Rmat=(1.0000 18.9751 1.0000 1.0000 33.8238) Rates=gamma Shape=0.1566 Pinvar=0;
[paste from the model test.outfile]
lscores 1;
bootstrap treefile=5deer_ml_bestmodel.tre replace nrep=10 /addseq=random nreps=10 swap=tbr;
log stop;
quit;
END;
download here 5deer_ml_bestmodel.nex
4) You can run it locally, or run it on condor without repmaker, or run it with repmaker first then run it on condor.
Below the submit description file (file name 5deer_ml_bestmodel.submit)
#################
#
# maximum likelihood after model test (substitution model comparison)
#
#################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = 5deer_ml_bestmodel.output
error = 5deer_ml_bestmodel.error
log = 5deer_ml_bestmodel.log
Arguments = 5deer_ml_bestmodel.nex -n
Queue
download here 5deer_ml_bestmodel.submit
test molecular clock
Once the appropriate likelihood model has been selected by ModelTest, one can test for a clock.
1) data file and paup block
Data file is the same as the Maximum Likelihood example. You can
download here 5deer_clock.nex .
paup file name "ml_testclock.nex"
#nexus
begin paup;
set autoclose=yes warnreset=no increase=auto;
execute 5deer_clock.nex;
log file=5deer_clocktest.log;
exclude all;
include 12S 16S COX1 CYTB /only;
set criterion=likelihood;
lset clock=no;
Lset Base=(0.3342 0.2443 0.1336) Nst=6 Rmat=(1.0000 18.9751 1.0000 1.0000 33.8238)
Rates=gamma Shape=0.1566 Pinvar=0;
[pasted from ModelTest]
hsearch;
lscore;
[!Non-clock score above, clock score below];
root rootmethod = midpoint;
lset clock=yes;
Lset Base=(0.3342 0.2443 0.1336) Nst=6 Rmat=(1.0000 18.9751 1.0000 1.0000 33.8238)
Rates=gamma Shape=0.1566 Pinvar=0;
[pasted from ModelTest];
[!Clock score above];
hsearch;
lscore;
log stop;
quit;
end;
download here ml_testclock.nex .
2) submit descrtption file
file name "ml_testclock.submit"
###########################################
#
# test molecular clock using Maximum likelihood
#
##########################################
Universe = standard
Executable = /cluster/bin/condor_paupdev
output = ml_testclock.output
error = ml_testclock.error
log = ml_testclock.log
Arguments = ml_testclock.nex -n
Queue
download here ml_clock.submit
3) After your job finished, you cat open the paup log file 5deer_clocktest.log to view two ln likelihood scores. Take the difference between the scores and double it. This is your test statistic for a chi-squared test; the number of taxa minus 2 is the degrees of freedom. You can use a program such as Microsoft Excel (the chidist function) or
this web site to compute the p-value. Significant p-values mean that the clock is rejected.