jointly estimating the alignment and presence of positive-selection with bali-phy

8 views
Skip to first unread message

samuel.e....@gmail.com

unread,
May 31, 2020, 11:57:34 PM5/31/20
to bali-phy-users
Hi, 

Just read the paper "Erasing Errors due to Alignment Ambiguity When Estimating Positive Selection". Bali-phy seems like a great tool for reducing false-positives in evaluating genes under positive selection. I installed Bali-Phy but can't seem to find the command to run the joint estimation of alignment and positive-selection illustrated in the manuscript. In the manual I saw the line of code

bali-phy alignment.fasta -S branch_site -T tree.tree --disable=topology

but this seems to require creating a multiple sequence alignment and phylogenetic tree prior to running the branch-site test. Has the method of simultaneously aligning and testing whether a gene is under positive selection implemented in Bali-phy yet? If so, how would you do this?

Thank you very much!

Best,
Sam Zimmerman

Benjamin Redelings

unread,
Jun 1, 2020, 12:02:26 AM6/1/20
to bali-ph...@googlegroups.com

Hi Sam,

The command line you gave looks right.  This requires knowing the tree first, but it does not require knowing the alignment first.  The file "alignment.fast" just needs to contain the sequences -- they don't need to be aligned.

I can change the documentation to call the file "sequences.fasta" if that is less confusing?

Incidentally, the only reason that you are required to know the tree first is that the branch-site test make the assumption that branches are fixed when labeling foreground/background branches.

-BenRI

--
You received this message because you are subscribed to the Google Groups "bali-phy-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bali-phy-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bali-phy-users/fe03bedb-10b9-4d96-9b72-ead02e6cb68f%40googlegroups.com.

Samuel Zimmerman

unread,
Jun 1, 2020, 10:49:03 AM6/1/20
to bali-phy-users
Hi BenRI,

Thanks so much for the quick response. When I tried that line of code, I got an error saying "Sequence contains 1 stop codons: not allowed!" 

This is completely understandable since I am using a DNA fasta file but a codon substitution model is used for positive-selection detection, and the command worked once I manually removed TGA from the end of each DNA sequence. I guess my concern is that manually removing TGA from the end of each contig feels a bit risky too me. There are tools like pal2nal to convert DNA sequences to codons, but these tools, as far as I know, require you to do multiple sequence alignment prior to conversion to codon files. So do you have any recommendations for converting sequences from nucleotides to codons?

Thanks again!

Best,
Sam

On Monday, June 1, 2020 at 12:02:26 AM UTC-4, benjamin...@gmail.com wrote:

Hi Sam,

The command line you gave looks right.  This requires knowing the tree first, but it does not require knowing the alignment first.  The file "alignment.fast" just needs to contain the sequences -- they don't need to be aligned.

I can change the documentation to call the file "sequences.fasta" if that is less confusing?

Incidentally, the only reason that you are required to know the tree first is that the branch-site test make the assumption that branches are fixed when labeling foreground/background branches.

-BenRI

On 5/31/20 8:14 PM, samuel.e...@gmail.com wrote:
Hi, 

Just read the paper "Erasing Errors due to Alignment Ambiguity When Estimating Positive Selection". Bali-phy seems like a great tool for reducing false-positives in evaluating genes under positive selection. I installed Bali-Phy but can't seem to find the command to run the joint estimation of alignment and positive-selection illustrated in the manuscript. In the manual I saw the line of code

bali-phy alignment.fasta -S branch_site -T tree.tree --disable=topology

but this seems to require creating a multiple sequence alignment and phylogenetic tree prior to running the branch-site test. Has the method of simultaneously aligning and testing whether a gene is under positive selection implemented in Bali-phy yet? If so, how would you do this?

Thank you very much!

Best,
Sam Zimmerman
--
You received this message because you are subscribed to the Google Groups "bali-phy-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bali-ph...@googlegroups.com.

Benjamin Redelings

unread,
Jun 1, 2020, 12:01:20 PM6/1/20
to bali-ph...@googlegroups.com

I guess I should point out that if you use a site model, such as m8a, then the tree and the alignment will both be estimated:

bali-phy sequences.fasta -S m8a_test

-BenRI

Reply all
Reply to author
Forward
0 new messages