dapc.biplot.arrange: Arrange list of ggplot biplots Function to arrange ggplot...

View source: R/DAPC_adegenet.R

dapc.biplot.arrangeR Documentation

Arrange list of ggplot biplots Function to arrange ggplot biplots for each pair of DFs or PCs of each K Max number of plots = 25.

Description

Arrange list of ggplot biplots

Function to arrange ggplot biplots for each pair of DFs or PCs of each K Max number of plots = 25.

Usage

## S3 method for class 'biplot.arrange'
dapc(
  x,
  layout.mat = NULL,
  row.labels.left = NULL,
  col.labels.top = NULL,
  row.labels.right = NULL,
  col.labels.bottom = NULL,
  use.diag = NULL,
  pad = 0.1,
  K = NULL,
  outer.text = list(NULL, NULL, NULL, NULL),
  maxMat = c(4, 4)
)

Arguments

x

A list of ggplots produced by ggscatter.dapc function

layout.mat

Custom layout matrix to use. Default is NULL, in which case the layout will be generated automatically as a fucnton of the number of plots.

row.labels.left

Text labels to use to the left of the first column of plots. Default NULL (no labels).

col.labels.top

Text labels to use above the first row of plots. Default NULL (no labels).

row.labels.right

Text labels to to the right of the last column of plots. Default NULL (no labels).

col.labels.bottom

Text labels to use below the bottom row of plots. Default NULL (no labels).

use.diag

NULL (the default) or numerical vector with values in 1:4, indicating which sides of the gtable (1=bottom, 2=left, 3=top, 4=right) should have labels applied to the diagonal rather than the table margin plots. Ignored if layout.mat is not square. For example, if use.diag=1, then the values of col.labels.bottom will appear below the plots on the diagonal rather than below the plots of the bottom row.

pad

Amount of space between plots, in units of line widths (Default 0.1).

K

Which set of biplots to use. If NULL (the default), the function will attemp to draw all biplots for all K (max 25 plots).

outer.text

A list with length=4, with each entry either NULL (the default) or character string to use as labels below, left, above, and to the right of the arrangement of plots.

maxMat

Numerical vector with length 2 that specifies the maximum number of rows and columns of plots, respectively, in the output gtable. Default = c(7,8).

Value

A gtable object


JeffWeinell/misc.wrappers documentation built on Sept. 20, 2023, 12:42 p.m.