check #seqs and tree: maybe too many '('

42 views
Skip to first unread message

Maya G

unread,
Mar 26, 2024, 4:33:20 AMMar 26
to PAML discussion group

Hi,

I'm new to PAML, and I'm attempting to run codeml, but it's giving me an error: “check #seqs and tree: maybe too many '('”

I can't figure out where the problem lies in my tree file, I'd appreciate it if someone could help.

Thank you!

tree.txt

Sandra AC

unread,
Mar 28, 2024, 7:27:25 AMMar 28
to PAML discussion group
Hi Maya,

Thanks for your message! I can see that your input tree file has branch lengths, which should not be included. In addition, you do not have a PHYLIP header indicating the number of species and trees (i.e., first line should have a format such as "<num_species> 1" which, in your case, would be "13 1", if I have not made a mistake when counting the number of taxa in your phylogeny). Note that all formatting requirements are detailed in the PAML documentation and in the PAML Wiki on the GitHub repository where it is hosted (check the PAML Wiki via this link).

Once you have modified your tree accordingly, try to re-run again CODEML and let us know if that worked! If other issues arise, please also share with us your control file and all your input files (alignment and tree file) so that we can further troubleshoot :)

All the best,
S.

Maya G

unread,
Mar 28, 2024, 9:16:22 AMMar 28
to PAML discussion group

Hi, thank you very much for your response! I attempted to fix the tree, but I'm still encountering the same issue. I've attached the corrected tree file along with the alignment file.
ב-יום חמישי, 28 במרץ 2024 בשעה 13:27:25 UTC+2, sandr...@gmail.com כתב/ה:
‏‏tree2.txt
input2.nuc

Sandra AC

unread,
Mar 28, 2024, 12:51:28 PMMar 28
to PAML discussion group
Hi there,

Can you also attach your control file? Otherwise, I cannot run CODEML with the same settings you have nor reproduce your error.

Thanks!
S.

Maya G

unread,
Mar 28, 2024, 1:44:09 PMMar 28
to PAML discussion group
Hi, sure, I forgot to attach it. Here's the control file (I am using PAMLX). Thank you very much!

ב-יום חמישי, 28 במרץ 2024 בשעה 18:51:28 UTC+2, sandr...@gmail.com כתב/ה:
codeml.ctl.tmp

Sandra AC

unread,
Mar 28, 2024, 2:58:59 PMMar 28
to PAML discussion group
Hi there,

It seems that you had double brackets to specify a clade (i.e., same clade was repeated twice with the opening/closing parentheses). The issue was here:
issue_parentheses.png

If you use an IDE such as Visual Studio Code or a text editor such as Notepad++ or Sublime (there are many more, just naming some!), it would be easier for you (and for other users who may encounter this problem) to identify whereabouts there are additional parentheses in your Newick-formatted tree :) 

In addition, please note that the PAML-X GUI has not been maintained for years, and hence its usage is not recommended. Instead, all PAML programs should be executed via the terminal. I am not entirely sure what kind of analysis you want to run with CODEML as there are many options in the control file that perhaps you do not even need to have there (not sure how you generated the control file nor the analysis you are running, so just guessing!). If you want to run CODEML to test for positive selection, however, then I suggest you read our latest protocol "Beginner's guide on the use of PAML to detect positive selection" (Álvarez-Carretero et al., 2023), where we explain in detail the various steps to follow to run such tests with CODEML. You should read this protocol alongside our `positive-selection` GitHub repository -- they are supposed to be read together as theory+practical! You can find various template control files that you can use to run your analyses depending on which model you want to run (e.g., homogenous model, site models, branch models, branch-site models) -- just follow the instructions in the `README.md` files :)

Hope these suggestions help with your analyses!

All the best,
S.
tree2.txt
Reply all
Reply to author
Forward
0 new messages