Skip to content

Commit

Permalink
Divide RGB colors by 255, not 256. Fixes #32
Browse files Browse the repository at this point in the history
  • Loading branch information
wch committed Jan 31, 2013
1 parent 8af3e4f commit 399f8fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/colour-manip.r
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#' col2hcl(colors())
col2hcl <- function(colour, h, c, l, alpha = 1) {

rgb <- t(col2rgb(colour)) / 256
rgb <- t(col2rgb(colour)) / 255
coords <- convertColor(rgb, "sRGB", "Luv")

# Check for correctness
Expand Down

0 comments on commit 399f8fa

Please sign in to comment.