Learn R Programming

ImaginR (version 0.1.7)

hex2rgb: Give RGB color code from HEX color code

Description

Give a RGB color code matrix from HEX color code vector.

Usage

hex2rgb(color.vector)

Arguments

color.vector

HEX code in a vector

Value

RGB code color

Examples

Run this code
# RGB color code of "Alice Blue" color:
hex2rgb("#f0f8ff")
# RGB color code of "Red" color:
hex2rgb("#ff0000")
# RGB color code of "Green" color:
hex2rgb("#008000")

Run the code above in your browser using DataLab