-
Notifications
You must be signed in to change notification settings - Fork 2
mptp_exercise
Pas-Kapli edited this page Sep 23, 2016
·
20 revisions
$ git clone https://github.com/Pas-Kapli/mptp.git
$ cd mptp
$ ./autogen.sh
$ ./configure
$ make
$ sudo make install
$ mafft Anolis.fas > Anolis_mafft.fas
Need to be much more careful with the alignment when using datasets with many indels (e.g. 16S rRNA)
$ raxmlHPC-PTHREADS-SSE3 -f c -s Anolis_mafft.fas -m GTRGAMMA -n read_alignment
On the screen and the RAxML_info.read_alignment file there is the following information
Found 13 sequences that are exactly identical to other sequences in the alignment.
Normally they should be excluded from the analysis.```
A reduced file is automatically created: Anolis_mafft.fas.reduced in phylip format
Check the difference:
```$ head -n 1 Anolis_mafft.fas.reduced```
```$ grep ">"```
```grep ">" Anolis_mafft.fas | wc -l ```
_**Q: How many sequences were in the fasta file and how many are there in the reduced phylip file?**_
#### Convert phylip to fasta (we will need it for mptp):
``` $ phylip_to_fasta.py Anolis_mafft.fas.reduced ```
The output file will be named Anolis_mafft.fas.reduced.fasta
### 1.3. Infer phylogenetic tree with RAxML:
``` $ raxmlHPC-PTHREADS-SSE3 -s Anolis_mafft.fas.reduced.fasta -m GTRGAMMA -n Anolis -p $RANDOM -T 2 -o GBGC12094-13_Polychrus ```
_Using the -o argument we retrieve a rooted phylogeny, if not then we can root it with mptp later_
## ``Species'' delimitation with mptp:
Check the mptp options:
```$ mptp --help```
Run delimitation with the multi-rate algorithm
_If the phylogeny is unrooted use the ``--outgroup taxon_name1,taxon_name2'' for rooting the phylogeny prior to the delimitation_
``` $ mptp --ml --multi --tree_file RAxML_bestTree.Anolis --output_file Anolis_multi_delimitation ```
Check the output files:
``` $ firefox Anolis_multi_delimitation.svg ```
``` $ nano Anolis_multi_delimitation.txt ```
Q: How many putative species are delimited?
Detect minimum branch length:
``` $ mptp --tree_file RAxML_bestTree.Anolis --minbr_auto Anolis_mafft.fas.reduced.fasta --output_file minbr ```
Re-run delimitation taking the minimum branch length into account:
``` $ mptp --ml --multi --tree_file RAxML_bestTree.Anolis --output_file Anolis_multi_delimitation --minbr 0.0014695325 ```
Re-run but crop the outgroup taxa:
``` $ mptp --ml --single --tree_file RAxML_bestTree.Anolis --output_file signle --outgroup GBGC1209413_Polychrus --outgroup_crop ```
_**Q: Does the delimitation change when by using the minimum branch length or the crop-outgroup command? Why? When would these options matter?**_
Repeat the exercise with the single-rate algorithm:
_**Q: How do the results differ from the multi-rate PTP?**_
1.5. Support values:
Perform MCMC sampling (proportional to the likelihood) for the multi and the single rate PTP:
``` $ mptp --tree_file RAxML_bestTree.Anolis --minbr 0.0014695325 --mcmc 10000000 --mcmc_log 1000000 --multi --mcmc_runs 2 --output_file mcmc_multi ```
``` $ firefox mcmc_multi.SOME_NUMBER.combined.svg ```
_**Q: Did the two runs converge?**_
_**Q: Did the runs converge to the Maximum Likelihood solution?**_