Closed tdelmont closed 7 years ago
We had talked about this before, Ozcan. We use a newick tree to organize everything, but what if we didn't have a tree?
It would have been great if anvi'o could order items in the view data alphabetically if no tree is provided :)
So instead of looking like this:
It will look like this:
Maybe there should be a callback function for samples order? A one that would return (None, newick)
when tree is present, and (simple_order, None)
when there is no tree (and simple order would be the order of items). Open to more elegant ideas :)
I have thought about this feature, It is tricky but possible and I have started to do some changes, but It needs some core changes since I have built everything top of tree data structure ( even the filename is treelib.js 😄 ), So It is better to keep everything in a new branch for now.
And at a beginning I am aiming to use the order in view data, but if I can finish that, We can extend the scenarios like alphabetical ordering, user provided list etc.
Yay :)
Yes, this will be a fundamental change in many ways, but I think it is a fun challenge. Thank you very much for looking into this.
I also agree that starting with the order in the view data is very appropriate. We can expand from there once everything else is in place.
Please let me know if there is anything I can help!
Where are we with this? :)
Hey Meren, This feature is ready i forgot to link commits to this issue sorry :/ , So the only thing we need is /tree/xxxx endpoint that returns json array instead of newick string.
Hi,
I am now working on a particular genome, and I would like to keep the order of genes (a gene is a leave) and display coverage values across environmental samples! Exciting.
Ozcan, I don't know if this is difficult to implement but it would be great if you can manage to make it work :)
tom