Export symbol as png

Posted by Etiennebr on Stack Overflow See other posts from Stack Overflow or by Etiennebr
Published on 2010-05-03T14:02:04Z Indexed on 2010/05/03 14:08 UTC
Read the original article Hit count: 270

Filed under:

I'd like to export plotting symbols form R as a png graphic. But I haven't found a perfect way yet.

Using

png("symbol.png",width=20, height=20, bg="transparent")
par(mar=c(0,0,0,0))
plot.new()
symbols(1, 1, circles=0.3, bg=2, inches=FALSE, lwd=2, bty="n")
dev.off()

creates a little border around the symbol (I'd like it to be transparent) and the symbol isn't filling the whole space.

Is there a more specific way of doing this ?

© Stack Overflow or respective owner

Related posts about r