Description Usage Arguments Details Value Author(s) Examples
This function creates a vector of n
equally spaced colors along the
'HP colour map' of your selection
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
n |
The number of colors (≥ 1) to be in the palette. |
alpha |
The alpha transparency, a number in [0,1], see argument alpha in
|
begin |
The (corrected) hue in [0,1] at which the hp colormap begins. |
end |
The (corrected) hue in [0,1] at which the hp colormap ends. |
direction |
Sets the order of colors in the scale. If 1, the default, colors are ordered from darkest to lightest. If -1, the order of colors is reversed. |
option |
A character string indicating the colourmap from a option to use. Four houses are available: "Gryffindor", "Slytherin", "Ravenclaw" and "Hufflepuff". |
house |
Depcreated. Use 'option' instead. |
Semi-transparent colors (0 < alpha < 1) are supported only on some
devices: see rgb
.
hp
returns a character vector, cv
, of color hex
codes. This can be used either to create a user-defined color palette for
subsequent graphics by palette(cv)
, a col =
specification in
graphics functions or in par
.
Alejandro Jiménez Rico aljrico@gmail.com, Personal Blog
1 2 3 4 5 6 7 8 9 10 11 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.