Learn R Programming

TRSbook (version 1.0.2)

camembert: Pie chart

Description

A variant of the pie function

Usage

camembert(x, col = NULL, family="Courier")

Arguments

x

qualitative variable

col

vector of characters for the color of each modality

family

font family for the title. Default is "Courier". Another choice can be, e.g., "HersheyScript"

Value

A pie chart

References

Chapter 11 (Descriptive Statistics) from the book: The R Software, Fundamentals of Programming and Statistical Analysis

See Also

pie

Examples

Run this code
# NOT RUN {
data(NUTRIELDERLY)
attach(NUTRIELDERLY)
require("RColorBrewer")
col <- brewer.pal(8,"Pastel2")
camembert(fat,col)
detach(NUTRIELDERLY)
# }

Run the code above in your browser using DataLab