netVisual_chord_cell - netVisual_individual - par(mfrow) and title.name do not display
When using the netVisual_Chord_cell the par(mfrow, c(2,1)) and title.name function do not work.
par(mfrow = c(2,1))
netVisual_chord_cell(cellchatF7Ctrl, sources.use = group.new[i], signaling = "GRN", slot.name = "net", show.legend = TRUE, scale = F, nCol = 2, lab.cex = 2, small.gap = 5, title.name = paste0(pathways.show[1]))
netVisual_chord_cell(cellchatF7, sources.use = group.new[i], signaling = "GRN", slot.name = "net", show.legend = TRUE, scale = F, nCol = 2, lab.cex = 2, small.gap = 5, title.name = paste0(pathways.show[1]))
I'm using markdown and this code plots 2 times 2 plots (2 times the first and two times the second)
Hello,
I'm having a similar issue for the functions "netVisual_circle" and "netVisual_aggregate". The title is blank. I was wondering if you found a solution for this?
Thank you, Jessica
@JessicaChevallier You may explicitly add text(0,1.5,title.name, cex = 1.1) after running this function.
Hello,
Thank you, but, that does not seem to work for me. I used the following after running the function to add a title.
title("title you want")
Thanks! Jessica
Hi all
This might help.
https://github.com/sqjin/CellChat/issues/670#issuecomment-1710193590
When
netVisual_circlebuilds the plot object,title.namewas appended afterplot()event has happened. When actually showing the figure, plotting is clipped to the plot region (default ispar(xpd = FALSE)), hence title is clipped out.We need to explicitly set
par(xpd = TRUE)so that plotting is clipped to the figure region (i.e. that also includes title).par(xpd = TRUE) netVisual_circle(cellchat@net$count, vertex.weight = groupSize, weight.scale = TRUE, label.edge = FALSE, title.name = "Number of interactions")