Description Usage Arguments Examples
View source: R/ggconventions.r
c_transform
replaces or adds series to data frames with convention
aware series, c_fortify
is a wrapper around c_transform
that defaults to adding new series rather than replacing series
1 2 3 4 |
data |
Data frame |
variables |
Which variables to transform, if NULL try all of them |
fortify_data |
If TRUE add new variables with |
prefix |
Prefix to use if |
1 2 3 4 5 6 7 | require("ggplot2")
source(system.file("conventions/gender.R", package="ggconventions"))
data("gender_data", package="ggconventions")
qplot(x=class, y=survivors, colour=gender, shape=gender,
data=c_transform(gender_data), geom="blank") + geom_point(size=5)
qplot(x=class, y=survivors, colour=gender, shape=c.gender,
data=c_fortify(gender_data), geom="blank") + geom_point(size=5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.