You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
why the use of row names as node names? I personally think it's much harder to work with rownames than with just another column in the data frame. It would also make more sense from a reading perspective that the parent is listed to the left of the node, so a data frame with the columns c('parent', 'node'). Also this would make it more consistent with the gene label data frames later on.
The root node does have a parent and the parent is the germline or normal. Instead of using an NA which can cause various trouble later on, why not use 0?
Branch Lengths
There is some typo in this line:
Up to twoIncluding a length1 and/or length2 column will enable this branch scaling behaviour, and automatically add y-axis ticks and labels.
Instead of making the user hard code the data frame length1 and length2 (and promptly forgetting what they stand for), why not take 2 arguments that specify which column should be taken as length1 and which column as length2? That way you will also automatically have y-axis titles?
Showing Cellular Prevalence
Not that it really matters for the visualization, but cellular prevalence is the proportion of cells that belong to each cluster in the entire sequenced sample. The example shown (where the CP of the root node is 1) is practically impossible in real life (because there is always going to be some stromal contamination in bulk sequencing), and is more reflective of the cancer cell fraction (CCF, the proportion of cells that belong to each cluster in the tumour cells sequenced). Question is, if the root node does not have CP = 1, does the function still work?
Branch Angles
Does it mean that setting NA to a particular angle will result it in being determined automatically?
CNAs and SNVs
This is cute but seems to introduce some novel conventions to tree plotting. I appreicate the ease where the user can just input a CNA and a SNV column, but is there options for the user to just specify some text, the branch and font / size / colour of the text?
Sometimes it's useful to specify text next to the node instead of the branch, could that be a feature request?
What's the difference between CNA = 0 and CNA = NA
Plot Width with Horizontal Padding
Where is the x-axis? Do you mean the y-axis?
Some plots require more or less horizontal padding between the x-axes and the tree itself.
Branch Scaling
I wonder if instead of 1 and 2, left and right might be better for specifying the two branches and the y-axis.
X-Axes
Some formating / typo for this section cuz the text is
A y-axis will be added automatically for each branch length column (the left-sided axis corresponding to the first branch length column, and the right with the second length column).
Axis Title
Strange use of parent.only as the example figure to demonstrate this section, that's a tree where the branch lines don't mean anything right? So the SNVs left y-axis doesn't make any sence?
Axis Tick Placement
This example is a little strange to me, what does the y-axis even mean if the doesn't cover the full length of the tree from to to bottom?
Thoughts from actually using the code
I think example code for how to change the colours of the nodes, branches, the CP shadings and the normal little square would be useful in this section. That was my first question anyways.
I'm not sure every new user would even know how to save the plot output to a file? Why is there no option to do that automatically? I had to use the pdf() and dev.off()
But the plot seems to output nodes 1:5 always. This is actually important since for mult-region SRC, not every cluster is in every sample but you need the node names to be consistent so you can tell which are the same clusters across samples.
5. For horizontal.padding, seems like anything below -1 doesn't do extra?
6. I generated some random length2 that is completely on a different scale as length 1, unfortunately the automatic system completely fell apart for this (SRCGrob(tree, yaxis1.label = 'SNVs', horizontal.padding = -2)), but I wouldn't say this is a completely outrageous example. Since SNV count in the ~10k range is not unheard of, and the number of driver SNVs for example would still be in the integer range
7. If a node has `CP = 0`, this error is outputted which is not the most informative
> Error in unit(x, default.units) : 'x' and 'units' must have length > 0
8. If a node has `CP > 1`, the same error is outputted lol
> Error in unit(x, default.units) : 'x' and 'units' must have length > 0
9. There might be something wrong with my cluster R environment set up, but the `italicize` of SNV labels didn't work for me
Thoughts to conclude
I didn't have much trouble creating the input data required for plotting, since I always worked with data frames in similar formats to represent my trees
Would love to see a list of all customizable options, I know lots of stuff is available looking at ?SRCGrob, but an naive user might not know where to look
Why the name SRCGrob for the main function of this package? Most people won't know what a grob is right? Maybe include a wrapper function called plotSRC or something and add the support for writing to file by including grid.plot?
Is there an ETA on multi-sample SRC plotting?
Well I hope that does it, @dan-knight let me know if there's any specific feedback you are looking for!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Set up
Thoughts from reading the user guide
Parent Data
c('parent', 'node')
. Also this would make it more consistent with the gene label data frames later on.Branch Lengths
length1
andlength2
(and promptly forgetting what they stand for), why not take 2 arguments that specify which column should be taken aslength1
and which column aslength2
? That way you will also automatically havey-axis
titles?Showing Cellular Prevalence
CP = 1
, does the function still work?Branch Angles
CNAs and SNVs
CNA = 0
andCNA = NA
Plot Width with Horizontal Padding
Branch Scaling
1
and2
,left
andright
might be better for specifying the two branches and the y-axis.X-Axes
Axis Title
parent.only
as the example figure to demonstrate this section, that's a tree where the branch lines don't mean anything right? So theSNVs
left y-axis doesn't make any sence?Axis Tick Placement
Thoughts from actually using the code
pdf()
anddev.off()
But the plot seems to output nodes
1:5
always. This is actually important since for mult-region SRC, not every cluster is in every sample but you need the node names to be consistent so you can tell which are the same clusters across samples.5. For
horizontal.padding
, seems like anything below-1
doesn't do extra?6. I generated some random
length2
that is completely on a different scale as length 1, unfortunately the automatic system completely fell apart for this (SRCGrob(tree, yaxis1.label = 'SNVs', horizontal.padding = -2)
), but I wouldn't say this is a completely outrageous example. Since SNV count in the ~10k range is not unheard of, and the number of driver SNVs for example would still be in the integer range7. If a node has `CP = 0`, this error is outputted which is not the most informative > Error in unit(x, default.units) : 'x' and 'units' must have length > 0 8. If a node has `CP > 1`, the same error is outputted lol > Error in unit(x, default.units) : 'x' and 'units' must have length > 0 9. There might be something wrong with my cluster R environment set up, but the `italicize` of SNV labels didn't work for me
Thoughts to conclude
?SRCGrob
, but an naive user might not know where to lookSRCGrob
for the main function of this package? Most people won't know what agrob
is right? Maybe include a wrapper function calledplotSRC
or something and add the support for writing to file by includinggrid.plot
?Well I hope that does it, @dan-knight let me know if there's any specific feedback you are looking for!
Beta Was this translation helpful? Give feedback.
All reactions