Open gwallau opened 11 months ago
Hi! Glad to hear you are trying out TreeViewer!
Do you mean something like just adding an offset to the scale axis (as is done in this BEAST tutorial), or something more elaborate?
Hello!
Exactly, I was thinking about offsetting the scale axis like this BEAST tutorial. Is the are any way of doing it in the Scale axis module or using another parameter?
Best, Gabriel
There is now 😉
I just pushed an update to the Scale axis module (v1.2.1). TreeViewer should prompt you to update (probably tomorrow or after midnight), but you can apply it by clicking on the Module repository
button in the Modules
tab, then selecting the Plot action
tab within the module repository, and clicking on the Install
button (this should be the only updated module).
After you have installed the module, open a tree file, add a scale axis, and make sure that:
Reverse axis
check box is checked (so that the tips have age 0).Negative ages
check box is checked (this is part of the new update and makes the ages negative).Offset
parameter (also part of the new update) corresponding to the age of the most recent tip (i.e., the rightmost tip).This should let you create a scale axis like the one in the tutorial.
If your branch length units are years, you may also want the tick spacing to make sense for this. For example:
Tick spacing
to 0.08333333333333333
(i.e. $\frac{1}{12}$) and Labels every
to 12
(i.e., $\frac{12}{1}$).Tick spacing
to 0.25
(i.e. $\frac{3}{12}$) and Labels every
to 4
(i.e., $\frac{12}{3}$).Tick spacing
to 0.33333333333333333
(i.e. $\frac{4}{12}$) and Labels every
to 3
(i.e., $\frac{12}{4}$).Tick spacing
to 0.5
(i.e. $\frac{6}{12}$) and Labels every
to 2
(i.e., $\frac{12}{6}$).Let me know if you have any issues!
Hi,
Thanks for the new implementation. I managed to set up it correctly once but now I'm having some errors while setting up the Age distribution plot like "Index was outside the bounds of the array". Even trying with the same tree and files I managed to get the distribution before. I tried to solve the issue setting up larger intervals of Width and Height in the Coordinates module. But the error persists... Do you have any tips to overcome this?
Important to say that I'm using beast trees files in the set up age distribution attachment.
Another issue is that I always get an error when I try to open all trees from beast into TreeViewer. Follow bellow the full error reported in my mac.
Hi, I'm sorry to hear that you're having issues... It would be helpful if you could send me some of the files that cause the problem, so I can reproduce and fix it on my end. If you don't want to upload them publicly here, you can email me at giorgio.bianchini (at) bristol.ac.uk.
Also, thank you for the macOS error report (I edited your comment to compress it as it was a bit long)! Unfortunately this kind of reports is not very helpful (since it was produced by macOS, it has a lot of low-level information, but it's missing the actual reason that caused the crash); again, it would be great if you could send me the file that causes the crash. Alternatively, you could try starting TreeViewer from a terminal window, with something like TreeViewer --log-exceptions > log.txt
, and making it crash. This should create a file called log.txt
that will contain all the errors that occurred while running the program, and would help diagnose the bug.
At least for this second problem, I expect that the issue is that the trees in the output file are very divergent, and this doesn't play well with the consensus method used by TreeViewer; in this case, it would probably be easier to compute the consensus tree using the BEAST TreeAnnotator, and then open that in TreeViewer (you should be able to add the age distributions by adding the file with all the trees as an attachment and using the Set up age distributions (attachment) module).
Congrats, you have developed a pretty nice tool! I'm testing it with beast analysis using time stamped viral genomes. I was trying to set the tree scale axis to year and months like I do in Figtree adding the date of the most recent sample, but it looks like TreeViewer is more tunnelled to million years scale. Is that correct?
Are there any way of adding the such scale for time stamped trees and converting automatically the timing to years and months?