[Rd] text(1:10, col=NA) is not transparent

From: Peter Ruckdeschel <peter.ruckdeschel_at_itwm.fraunhofer.de>
Date: Mon, 20 Feb 2012 12:09:55 +0100

Maybe I am missing something, but according to the help page to par (section "Color Specification"), which is referred to in the help to text argument col:

β€˜"transparent"’ or (integer) β€˜NA’ is _transparent_, useful for filled areas (such as the background!), and just invisible for things like lines or text.


col0 <- as.integer(NA)
### is this coercing to "integer" necessary?
text(1:10, col=col0)
### text is plotted

text(1:10, col="transparent")
### text is not plotted

# Of course, this is not terribly urgent, as a color value of 0 also plot(1:10)
text(1:10, col=0)
### text is not plotted

Best, Peter

R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Mon 20 Feb 2012 - 11:19:29 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 20 Feb 2012 - 16:10:20 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive