Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

phymltest() producing the double amount of trees #105

Open
mickvv opened this issue Nov 22, 2023 · 6 comments
Open

phymltest() producing the double amount of trees #105

mickvv opened this issue Nov 22, 2023 · 6 comments

Comments

@mickvv
Copy link

mickvv commented Nov 22, 2023

When running phymltest() with the 28 models, the produced treefile _phyml_tree.txt contains 56 trees instead of expected 28.

Is it normal ?

Thanks
Mick

@emmanuelparadis
Copy link
Owner

Maybe you called phymltest() twice? See ?unique.multiPhylo to try to check this.

Cheers,
Emmanuel

@mickvv
Copy link
Author

mickvv commented Nov 23, 2023

Thank you for your quick answer.

I run this command:
phyml.sylvia <- phymltest("sylvia.phy", execname="/usr/bin/phyml")
I've tried removing the _phyml_tree.txt output to avoid appending to the same file.
Thanks for the ?unique.multiPhylo, it is a useful command but in my case I go from 56 to 11 trees.
I also looked at the _phyml_stats.txt and there are indeed 28 runs listed.
It seems that for each model tested, 2 trees are produced but I don't know which one to choose out of the 56...
My goal is to get the tree for the best model.

Cheers,
Mick

@emmanuelparadis
Copy link
Owner

emmanuelparadis commented Nov 23, 2023

It seems like a bug in phyml. Using sequence data from here, the (shell) command:

phyml -i sylvia.txt

runs fine and creates the file 'sylvia.txt_phyml_tree.txt' with a single tree. Then if I run:

phyml -i sylvia.txt --append

the file has 3 trees (or 2 if I delete the output files beforehand).

I'm adding @stephaneguindon to this thread.

This is under Ubuntu (for me).

@mickvv Since each tree is duplicated, you should be able to get one tree out of two with:

TR <- read.tree("sylvia.phy_phyml_tree.txt") # using changed file extension
TR[c(TRUE, FALSE)]

Also, the next one should give you the same 28 trees:

unique.multiPhylo(TR, use.edge.length = TRUE)

Cheers,
Emmanuel

@emmanuelparadis
Copy link
Owner

Just checked my version number of phyml (under Ubuntu 22):

3:3.3.20211231-1

@mickvv
Copy link
Author

mickvv commented Nov 23, 2023

Thank you very much, I think it will do the trick !

Regards,
Mick

@stephaneguindon
Copy link

It seems like a bug in phyml. Using sequence data from here, the (shell) command:

phyml -i sylvia.txt

runs fine and creates the file 'sylvia.txt_phyml_tree.txt' with a single tree. Then if I run:

phyml -i sylvia.txt --append

the file has 3 trees (or 2 if I delete the output files beforehand).

I'm adding @stephaneguindon to this thread.

This is under Ubuntu (for me).

@mickvv Since each tree is duplicated, you should be able to get one tree out of two with:

TR <- read.tree("sylvia.phy_phyml_tree.txt") # using changed file extension
TR[c(TRUE, FALSE)]

Also, the next one should give you the same 28 trees:

unique.multiPhylo(TR, use.edge.length = TRUE)

Cheers, Emmanuel

Thanks. I will take a look at this issue.
Regards,
-Stephane-

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants