Learn R Programming

swfscMisc (version 1.6.5)

transparent: Transparent Colors

Description

Return transparent form of a named color.

Usage

transparent(col, percent = 50)

Arguments

col

vector of colors as name, hexadecimal, or positive integer (see col2rgb).

percent

percent of transparency (0 = solid, 100 = transparent).

Author

Eric Archer eric.archer@noaa.gov

Examples

Run this code

pct <- seq(0, 100, by = 10)
plot(pct, pct, bg = transparent("red", pct), pch = 21, cex = 4, xlab = "X", ylab = "Y")

Run the code above in your browser using DataLab