Comments (2)
thanks for reaching out. regarding your issues:
running
treetime ancestral --aln aln.fasta --tree phyliptree.phy
parses both alignment and tree ok, but the taxon names don't match sequence names in the alignment:
\:> treetime ancestral --aln aln.fasta --tree phyliptree.phy
0.00 -TreeAnc: set-up
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: Oryctolagus cuniculus
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: Ochotona princeps
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: Nannospalax galili
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: Fukomys damarensis
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: Jaculus jaculus
0.04 ERROR: At least 30\% terminal nodes cannot be assigned with a sequence!
The same problem is encountered when using new_tree.nwk
:
\:> treetime ancestral --aln aln.fasta --tree new_tree.nwk
0.00 -TreeAnc: set-up
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: 9986
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: 9978
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: 10020
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: 43179
0.04 ***WARNING: TreeAnc._attach_sequences_to_nodes: NO SEQUENCE FOR LEAF: 885580
0.05 ERROR: At least 30\% terminal nodes cannot be assigned with a sequence!
here, the issue is that your sequence names are of the form
>10181_0:002977
where the taxon names are only 10181_0
.
You need to make sure taxon names match sequence names (colons are not admissible in nwk anyway). Your phylip
alignment is not correctly parsed by biopython:
In [1]: from Bio import AlignIO
In [2]: AlignIO.read('aln.phylip', 'phylip-relaxed')
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
<ipython-input-2-211a42c6215e> in <module>()
----> 1 AlignIO.read('aln.phylip', 'phylip-relaxed')
from treetime.
Thanks for the quick reply, it worked great!
from treetime.
Related Issues (20)
- More than one record found in handle HOT 4
- how to convert the annotated nexus file (from treetime mugration) to JSON format? HOT 2
- New crash when running without alignment HOT 1
- Joint ancestral sequence reconstruction fails when input sequences are identical and GTR is inferred
- Not generating confidence intervals of divergence times, rate or root date HOT 1
- skyline: TypeError: can't multiply sequence by non-int of type 'float'
- ENH: Better error message when input alignment has sequences of unequal length HOT 1
- Newick formatting error fasttree HOT 3
- IndexError: too many indices for array: array is 1-dimensional, but 2 were indexed HOT 2
- [read_vcf] Convert ALT '*' to "N"
- [write_vcf] CHROM is "MTB_anc"
- ERROR: Cannot read metadata: need at least one column that contains the taxon labels. HOT 7
- Different output trees HOT 2
- How to resolve Polytomies in the tree HOT 2
- BUG: clock_filter_method='residuals' should be 'residual' HOT 1
- about the mugration HOT 2
- incorrectly mutation-annotated branch on phylogeny HOT 1
- TreeTimeUnknownError: Error: Unexpected behavior detected in multiply function when determining peak of function with y-values '[]'. HOT 6
- Question about branch length in mugration
- 'branch_mutations.txt' output always empty (v 0.11.3)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from treetime.