Description Usage Arguments Details Examples
View source: R/geom_circle_cm.R
This layer uses centimeter as unit to draw circles so
that the size and shape will not be influenced by
the change of the coordinate systems
(even when a polar system is used).
Note: this function does not have
linetype
and n
arguments.
1 2 3 4 5 6 7 8 9 10 11 |
mapping |
aes mapping. |
data |
data. |
stat |
stat. |
position |
position. |
na.rm |
logical, whether to remove NA values. |
show.legend |
whether to show legend. |
inherit.aes |
logical, whether to inherit aes from ggplot(). |
linetype |
should always be NULL. because it will not be used. |
... |
additional parameters. |
Accepted properties are:
(1) rcm
radius in centimeter.
(2) color
color of the outline.
(3) fill
color inside the shape.
(4) alpha
alpha of color and fill.
(5) size
line width of the outline.
(6) x
x coordinates of the middle points.
(7) y
y coordinates of the middle points.
1 2 3 4 | library(ggplot2)
dat=data.frame(x=1: 10, y=rep(5, 10), R=rep(c(0.5, 1), 5))
ggplot(dat)+xlim(0, 11)+ylim(1, 9)+
geom_circle_cm(aes(x=x, y=y, fill=factor(R)), rcm=dat$R, alpha=0.5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.