layers {Momocs} | R Documentation |
grindr layers for multivariate plots
Description
Useful layers for building custom mutivariate plots using the cheapbabi approach. See examples.
Usage
layer_frame(x, center_origin = TRUE, zoom = 0.9)
layer_axes(x, col = "#999999", lwd = 1/2, ...)
layer_ticks(x, col = "#333333", cex = 3/4, lwd = 3/4, ...)
layer_grid(x, col = "#999999", lty = 3, grid = 3, ...)
layer_box(x, border = "#e5e5e5", ...)
layer_fullframe(x, ...)
layer_points(x, pch = 20, cex = 4/log1p(nrow(x$xy)), transp = 0, ...)
layer_ellipses(x, conf = 0.5, lwd = 1, alpha = 0, ...)
layer_ellipsesfilled(x, conf = 0.5, lwd = 1, alpha = 0, ...)
layer_ellipsesaxes(x, conf = 0.5, lwd = 1, alpha = 0, ...)
layer_chull(x, ...)
layer_chullfilled(x, alpha = 0.8, ...)
layer_stars(x, alpha = 0.5, ...)
layer_delaunay(x, ...)
layer_density(
x,
levels_density = 20,
levels_contour = 4,
alpha = 1/3,
n = 200,
density = TRUE,
contour = TRUE
)
layer_labelpoints(
x,
col = par("fg"),
cex = 2/3,
font = 1,
abbreviate = FALSE,
...
)
layer_labelgroups(
x,
col = par("fg"),
cex = 3/4,
font = 2,
rect = TRUE,
alpha = 1/4,
abbreviate = FALSE,
...
)
layer_rug(x, size = 1/200, ...)
layer_histogram_2(x, freq = FALSE, breaks, split = FALSE, transp = 0)
layer_density_2(x, bw, split = FALSE, rug = TRUE, transp = 0)
layer_title(x, title = "", cex = 3/4, ...)
layer_axesnames(x, cex = 3/4, name = "Axis", ...)
layer_eigen(x, nb_max = 5, cex = 1/2, ...)
layer_axesvar(x, cex = 3/4, ...)
layer_legend(x, probs = seq(0, 1, 0.25), cex = 3/4, ...)
Arguments
x |
a list, typically returned by plot_PCA |
center_origin |
|
zoom |
|
col |
color (hexadecimal) to use for drawing components |
lwd |
linewidth for drawing components |
... |
additional options to feed core functions for each layer |
cex |
to use for drawing components |
lty |
linetype for drawing components |
grid |
|
border |
color (hexadecimal) to use to draw border |
pch |
to use for drawing components |
transp |
transparency to use (min: 0 defaut:0 max:1) |
conf |
|
alpha |
|
levels_density |
|
levels_contour |
|
n |
|
density |
|
contour |
|
font |
to feed text |
abbreviate |
|
rect |
|
size |
|
freq |
|
breaks |
to feed hist (default: calculated on the pooled values) |
split |
|
bw |
to feed density (default: stats::bw.nrd0) |
rug |
|
title |
to add to the plot (default |
name |
to use on axes (default |
nb_max |
|
probs |
|
Value
a drawing layer
See Also
grindr_drawers
Other grindr:
drawers
,
layers_morphospace
,
mosaic_engine()
,
papers
,
pile()
,
plot_LDA()
,
plot_NMDS()
,
plot_PCA()