I have a semi-melted data frame that looks like this:
head(final_melt)
Group Source variable value
Control Whole Kidney MZF1 0.23879
Contro
As an alternative to joran's answer for ggplot2 graphics only:
ggsave(filename="Whole Kidney.pdf")The ggsave will copy the last printed graphic. Or it can save a particular plot.
pggsave(filename="Whole Kidney.pdf", p)pdf(), png() etc.)dev.off().In that order.