Useful layers for building custom mutivariate plots using the cheapbabi approach. See examples.
layer_frame(x, center_origin = TRUE, zoom = 0.9)layer_axes(x, col = "#999999", lwd = 1/2, ...)
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_morphospace(x, position = c("range", "full", "circle", "xy",
"range_axes", "full_axes")[1], nb = 12, nr = 6, nc = 5, rotate = 0,
size = 0.9, col = "#999999", flipx = FALSE, flipy = FALSE,
draw = TRUE, ...)
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_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, ...)
a list, typically returned by plot_PCA
logical
whether to center the origin (default TRUE
)
numeric
to change the zoom (default 0.9
)
color (hexadecimal) to use for drawing components
linewidth for drawing components
additional options to feed core functions for each layer
linetype for drawing components
numeric
number of grid to draw
color (hexadecimal) to use to draw border
to use for drawing components
to use for drawing components
transparency to use (min: 0 defaut:0 max:1)
one of range, full, circle,
xy, range_axes, full_axes)
to feed morphospace_positions (default range
)
numeric
total number of shapes when position="circle"
(default 12
)
numeric
number of rows to position shapes (default 6
)
numeric
number of columns to position shapes (default 5
)
numeric
angle (in radians) to rotate shapes
when displayed on the morphospace (default 0
)
numeric
size to use to feed coo_template (default 0.9
)
logical
whether to flip shapes against the x-axis (default FALSE
)
logical
whether to flip shapes against the y-axis (default FALSE
)
logical
whether to draw shapes (default TRUE
)
numeric
between 0 and 1 for confidence ellipses
numeric
between 0 and 1 for the transparency of components
numeric
number of levels to use to feed MASS::kde2d
numeric
number of levels to use to feed graphics::contour
numeric
number of grid points to feed MASS::kde2d
logical
whether to draw density estimate
logical
whether to draw contour lines
to feed text
logical
whether to abbreviate names
logical
whether to draw a rectangle below names
to add to the plot (default ""
)
to use on axes (default "Axis"
)
numeric
number of eigen values to display (default 5
)
numeric
sequence to feed stats::quantile
and to indicate where to draw ticks and legend labels
grindr_drawers
Other grindr: drawers
,
mosaic_engine
, papers
,
pile
, plot_PCA