sqjin / CellChat

R toolkit for inference, visualization and analysis of cell-cell communication from single-cell data
GNU General Public License v3.0
637 stars 145 forks source link

Graph Labels Disappearing After Using CellChat for Awhile #402

Open troks27 opened 2 years ago

troks27 commented 2 years ago

Hello everyone,

It seems that after generating a few graphs on CellChat, all of a sudden the graphs start taking a really long time to load, and then load incompletely--without labels. For example, in the hierarchy plot, all of the dots and arrows will show, however, the cluster labels associated with each dot disappear. Restarting the R session fixes the issue, and the labels return, however, after awhile, they disappear again and load times for graphs significantly increase.

Has anyone else had this issue or knows of a solution?

monikaramos commented 2 years ago

I am having the same issue. Any fixes?

sqjin commented 2 years ago

@monikaramos I usually save the plots using the code below.

pdf(file = "circle_MIF_Arg1+Mac.pdf", width = 15, height = 7) par(mfcol = c(1,2), xpd=TRUE) for (i in 1:2) { netVisual_aggregate(object.list[[i]], signaling = pathways.show, layout = "circle", edge.weight.max = weight.max[1], edge.width.max = 10, signaling.name = paste(pathways.show, names(object.list)[i]),idents.use = "Arg1+ Mac",alpha.edge = 0.8, targets.use = NULL, color.use = color.use.list[[i]]) } dev.off()