Learn R Programming

colortools (version 0.1.5)

pizza: Pizza color wheel

Description

This function displays a color wheel with specified colors

Usage

pizza(colors, bg = "gray95", border = NA, init.angle = 105, cex = 0.8, lty = 1, labcol = NULL, ...)

Arguments

colors
a vector with R color names of colors in hexadecimal notation
bg
background color of the plot. Default "gray95"
border
color of the border separating the pizza slices
init.angle
integer value indicating the start angle (in degrees) for the slices
cex
numeric value indicating the character expansion of the labels
lty
argument passed to polygon which draws each slice
labcol
color for the labels (i.e. names of the colors)
...
graphical parameters (par) can be given as argument to pizza

Details

This function is based on the pie function

See Also

wheel

Examples

Run this code
# pizza color wheel for rainbow colors
pizza(rainbow(7))

# pizza color wheel for tomato (18 colors)
pizza(setColors("tomato", 18), bg = "gray20", cex = 0.7)

Run the code above in your browser using DataLab