Qbik
Qbik

Reputation: 6147

R plot legend with transparent background

How to R plot legend with transparent background when using plot() function ?

Upvotes: 16

Views: 26622

Answers (1)

Shicheng Guo
Shicheng Guo

Reputation: 1293

Use: bg="transparent" in

legend()

Such as:

legend("right",bg="transparent",col=c(as.numeric(unique(df$group2))),cex=0.5)

Upvotes: 31

Related Questions