caravagnalab / revolver

REVOLVER - Repeated Evolution in Cancer
https://caravagnalab.github.io/revolver/
64 stars 25 forks source link

Revolver_cluster and plot_clusters #44

Closed ybta2957e closed 2 years ago

ybta2957e commented 2 years ago

Hi, I ran revolver_cluster by following command and plot_clusters. The sample name in the pictures showed different colors in the cluster.

fit = revolver_cluster(
  new_fit,
  min.group.size = 2,
  patients = new_fit$patients,
  hc.method = "ward",
  split.method = "cutreeHybrid"
)

image

And I used the following parameter and the colors of patient id in the pictures look correct. split.method = "cutreeDynamic" image

Is there a way to avoid showing different colors in a cluster?

Best, Toby

caravagn commented 2 years ago

I think in the top case there is a visualisation bug (the colouring indeed) as suggested by the Warning message. I am happy to fix it but I would need the fit object to reproduce the error. Can you share that in some way?

Thanks

caravagn commented 2 years ago

I have checked your data. There is no bug on the revolver side. You are using "cutreeHybrid" as cutting method and that is the one responsible for dendrogram splitting. See that here plot_dendrogram(fit)

Notice that in your data, maybe due to the analysis you have carried out, the method does not suggest any cluster. In fact, the dendrogram is poorly informative

I think the best you can do is to re-think your analysis and better curate what drivers you include in your sample. You can use plots like

plot_trajectories_per_cluster(fit, min_counts = 2)

to decide what drivers have the strongest evolution-related signal