Visualizes the correlation results computed by correlateAll() and correlateAcross().

plotCorrplot(
  object,
  variable_set,
  method_corr = NULL,
  across = NULL,
  across_subset = NULL,
  relevel = NULL,
  variables_subset = NULL,
  phase = NULL,
  plot_type = "lower",
  display_diagonal = TRUE,
  signif_level = NULL,
  clr_low = "darkred",
  clr_high = "steelblue",
  shape = "tile",
  shape_size = 15,
  size_aes = FALSE,
  display_values = FALSE,
  values_alpha = 0.9,
  values_clr = "black",
  values_digits = 2,
  values_size = 4,
  draw_grid = TRUE,
  grid_clr = "black",
  grid_size = 0.5,
  ncol = NULL,
  nrow = NULL
)

Arguments

object

A valid cypro object.

variable_set

Character value. Denotes the variable set of interest. Use getVariableSetNames() to obtain all names of currently stored variable sets in your object.

method_corr

Character value. Denotes the correlation method of interest. Either 'pearson' or 'spearman'.

across

Character value, character vector or NULL (see details for more). Specifies the grouping variable of interest.

Use getGroupingVariableNames() to obtain all variable names that group the cells of your experiment in a certain manner.

across_subset

Character vector or NULL. Specifies the particular groups of interest the grouping variable specified in argument across contains.

If set to NULL all of them are chosen. You can prefix groups you are NOT interested in with a '-'. (Saves writing if there are more groups you are interested in than groups you are not interested in.)

Use getGroupNames() to obtain all valid input options.

relevel

Logical value. If set to TRUE the input order of across_subset determines the order in which the groups of interest are displayed. Groups that are not included are dropped which affects the choice of color.

variables_subset

Character vector or NULL. Specifies the numeric variables you want to be included in the correlation plot.

If set to NULL all of them are chosen. You can prefix variables you do NOT want to influence the clustering with a '-'. (Saves writing if there are more variables you are interested in than variables you are not interested in.)

phase

Character or numeric. If character, the ordinal value referring to the phase of interest (e.g. 'first', 'second' etc.). referring to the phase of interest or 'all'. If numeric, the number referring to the phase.

If set to NULL takes the phase denoted as default with adjustDefault().

Ignored if the experiment design contains only one phase.

plot_type

Character value. Either 'upper', 'lower' or 'complete'. Specifies how the correlation matrix is displayed.

display_diagonal

Logical value. Specifies if the diagonal of the correlation matrix is supposed to be included in the correlation plot.

signif_level

Numeric value or NULL. If numeric, specifies the minimum significance level a correlation pair must feature in order to be displayed. Insignificant correlation values are crossed out. Argument shape_size denotes the size of the crosses.

clr_low

Character value. Specifies the color used for the lower end of the colorspectrum (negative correlations).

clr_high

Character value. Specifies the color used for the upper end of the colorspectrum (positive correlations).

shape

Character value. Specifies the geometric objects with which to display the correlation pairs. Either 'tile' or one of 'circle' and 'rect'. In the latter two cases the size of the geometric objects can be used to emphasize the correlation in addtion to the colorspectrum if size_aes is set to TRUE.

shape_size

Numeric value. Specifies the size with which to display the circles and rectangulars. If shape_aes is set to TRUE it Specifies the maximum size possible.

size_aes

Logical value. If set to TRUE the size of the circles or rectangulars is used to display the correlation.

display_values

Logical value. If set to TRUE the actual correlation values are printed on the geometric objects.

values_alpha

Numeric value. Specifies the transparency of the values.

values_clr

Character value. Specifies the color of the values.

values_digits

Numeric value. Specifies the number of digits to which the correlation values are rounded before beeing displayed.

values_size

Numeric value. Specifies the size of the values.

draw_grid

Logical value. If set to TRUE a grid is drawn separating all circles or shapes.

grid_clr

Character value. Specifies the color of the grid.

grid_size

Numeric value. Specifies the thickness of the grid's lines.

ncol

Given to ggplot2::facet_wrap(). Affects the way the subplots are displayed.

nrow

Given to ggplot2::facet_wrap(). Affects the way the subplots are displayed.

Value

A ggplot.