Skip to content
This repository has been archived by the owner on Jan 24, 2024. It is now read-only.

Why do I always get two plots in the netVisual function (and cannot save either of them as a pdf or svg or png file as well) ? #625

Closed
PanYan-1130 opened this issue May 31, 2023 · 2 comments

Comments

@PanYan-1130
Copy link

When I use the netVisual function to draw plots, I always get a bigger plot at first and then a smaller one that follows. The same thing happens on netVisual_chord_gene, netVisual_individual, and netVisual_circle, but other functions such as plotGeneExpression are all fine. So I'm sure that it is not the R layout problem.

This is critical to me because I cannot save this plot as pdf or png, and svg shows broken when I using svglite to save plots as I searched for other answers.

Can anyone help me to just show a single plot in these functions, so that I can save it as svg correctly?

@sqjin
Copy link
Owner

sqjin commented Jun 2, 2023 via email

@PanYan-1130
Copy link
Author

I use pdf... dev.off() when running netVisual_chord_gene Please try below: par(mfrow = c(1,1), xpd=TRUE) cairo_pdf(file = "circle_KIT.pdf", width = 4, height = 4) netVisual_aggregate(object.list[[2]], signaling = "KIT", layout = "circle", signaling.name = paste("KIT", names(object.list)[2]), color.use = color.use) dev.off()

On Wed, May 31, 2023 at 9:43 AM PanYan-1130 @.> wrote: When I use the netVisual function to draw plots, I always get a bigger plot at first and then a smaller one that follows. The same thing happens on netVisual_chord_gene, netVisual_individual, and netVisual_circle, but other functions such as plotGeneExpression are all fine. So I'm sure that it is not the R layout problem. This is critical to me because I cannot save this plot as pdf or png, and svg shows broken when I using svglite to save plots as I searched for other answers. Can anyone help me to just show a single plot in these functions, so that I can save it as svg correctly? — Reply to this email directly, view it on GitHub <#625>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHXF63HZSMT5IAZW6COZI4LXI2O33ANCNFSM6AAAAAAYUYN3ZE . You are receiving this because you are subscribed to this thread.Message ID: @.>

Thank you. This can work with R script.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants