-
Notifications
You must be signed in to change notification settings - Fork 1
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
Split "plot_tree" phases #7
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me - much easier to read when the code is in smaller, separate function. The version number in the Description and NEWS file need bumped before merging, but otherwise happy for you to merge whenever :)
d630c3c
to
75f0a75
Compare
@jr-nicola I've bumped the version of the package now. Could you approve please. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Russ - looks good
Aim: simplify the definition / saving of the tree images in
treeview()
function.The tree images are created by the
.plot_tree()
inner function. But, sinceplot_tree
depended on a lot of variables in thetreeview()
scope, it wasn't easy to pullplot_tree()
out in one go..plot_tree()
had a few separate stages: The creation of a non-interactive ggtree object, the creation of an interactive ggtree object, the conversion of the latter into an htmlwidget, and the saving of some of these objects.The changes here (which build upon #6 ) extract those inner phases of
.plot_tree
and all variables used by the new functions are passed in as arguments, to isolate them from the plot_view scope.A further PR, where
plot_tree
is separated into the steps that make the tree objects, and the steps that save them, and extract those functions from theplot_tree
scope builds upon this in [TODO]