Closed stanaka6 closed 1 year ago
Hi @stanaka6, thank you for the interest in ktplots
.
keep_significant_only
is passed to plot_cpdb
where significant interactions are additionally labelled with the highlights. The current trimming occurs on the cellphonedb output but row-wise, i.e. only keeps the interaction if there is at least 1 celltype-celltype pair that shows the significant interaction. Therefore, how it works currently is a feature for plot_cpdb. I can see why one would want to just only keep the significant hits. I will have to look into this further to implement the ability to just show the actual significant only.
yes. it still scales to 0 to 1 because you had standard_scale = TRUE
. just toggle that to FALSE
, as well as scale = FALSE
. For clarity, both scale
(z-score) and standard_scale
(0 to 1) are default TRUE
. Toggling both to FALSE
should revert to the original p-value.
you are right. my apologies. it seems i have switched the width
and alpha
parameters at some point. let me look into this further.
Should also mention that you are also welcomed to put in PRs to toggle the behaviours you want.
Thank you for your answers! Any updates?
hi @stanaka6, sorry i haven't had time to work on this. progress will be a bit slow.
@stanaka6, hi, can you give the version in my #79 PR a go?
devtools::install_github('zktuong/ktplots', ref = 'flip-colour-order')
I've added in an argument plot_score_as_thickness
that takes TRUE/FALSE
to toggle the thickness versus alpha scaling. let me know if that works for you
Hello,
Thank you very much for providing a wonderful tool!
I have a few questions about plot_cpdb2:
I set
keep_significant_only = TRUE
, but it looks like non-significant interactions are still in my plot. Could you please let me know how I can solve this problem? I have looked at the source code of plot_cpdb2 but couldn't find the codes to exclude non-significant ones even if keep_significant_only = TRUE. I would be grateful if you could provide me with any clarification.Is -log10(sig) is equal to -log10(p-value)? If so, why is the range from 0 to 1? Is it possible to show the original -log10(p-value) as 0<~infenity?
In my plot, interaction scores are represented by line colors, and -log10(sig) is represented by the thickness of the bars, unlike the plot in the example (opposite: thickness - score, -log10(sig) = colors. Why that happens, and would it be possible to use the same way in the example?
Here is my code:
This is the legend of my plot (hiding cell-type information)
Any comments and suggestions would be very much appreciated.
Thanks!