plotBoxplot: Plot numeric distribution and statistical tests

Description Usage Arguments

View source: R/plot-family-statistics.R

Description

These functions display the distribution of numeric variables for the whole sample or in a comparative manner if argument across is specified. plotViolinplot() and plotBoxplot allow for statistical tests such as t-test or ANOVA.

Usage

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
plotBoxplot(
  object,
  variables,
  phase = "all",
  across = NULL,
  across_subset = NULL,
  relevel = TRUE,
  clrp = "milo",
  clrp_adjust = NULL,
  test_groupwise = NULL,
  test_pairwise = NULL,
  ref_group = NULL,
  step_increase = 0.01,
  vjust = 0,
  display_facets = TRUE,
  scales = "free",
  nrow = NULL,
  ncol = NULL,
  display_points = FALSE,
  pt_alpha = 0.8,
  pt_clr = "black",
  pt_num = 100,
  pt_size = 1.25,
  pt_shape = 21,
  verbose = TRUE,
  ...
)

plotDensityplot(
  object,
  variables,
  phase = "all",
  across = NULL,
  across_subset = NULL,
  relevel = NULL,
  clrp = "milo",
  clrp_adjust = NULL,
  display_facets = TRUE,
  scales = "free",
  nrow = NULL,
  ncol = NULL,
  verbose = TRUE,
  ...
)

plotHistogram(
  object,
  variables,
  phase = "all",
  across = NULL,
  across_subset = NULL,
  relevel = TRUE,
  clrp = "milo",
  clrp_adjust = NULL,
  scales = "free",
  nrow = NULL,
  ncol = NULL,
  verbose = TRUE,
  ...
)

plotRidgeplot(
  object,
  variables,
  phase = "all",
  across = NULL,
  across_subset = NULL,
  relevel = TRUE,
  alpha = 0.8,
  clrp = "milo",
  clrp_adjust = NULL,
  scales = "free",
  nrow = NULL,
  ncol = NULL,
  verbose = TRUE,
  ...
)

plotViolinplot(
  object,
  variables,
  phase = "all",
  across = NULL,
  across_subset = NULL,
  relevel = TRUE,
  clrp = "milo",
  clrp_adjust = NULL,
  test_groupwise = NULL,
  test_pairwise = NULL,
  ref_group = NULL,
  step_increase = 0.01,
  display_facets = TRUE,
  vjust = 0,
  scales = "free",
  nrow = NULL,
  ncol = NULL,
  display_points = FALSE,
  pt_alpha = 0.8,
  pt_clr = "black",
  pt_num = 100,
  pt_size = 1.25,
  pt_shape = 21,
  verbose = TRUE,
  ...
)

Arguments

object

A valid cell tracer object.

phase

Character value. Refers to the phase of the experiment. Valid inputs are:

'before_tmt'

Uses the data that refers to the time before the treatment.

'first_tmt'

Uses the data that refers tot the time after the treatment.

Note: This argument is ignored if the experiment set up did not include any treatment or the treatment started right from the beginning.

across

Character value or NULL. Specifies the grouping variable of interest.

Use getGroupingOptions() 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 colors with which they are displayed.

clrp

Character value. Specifies the color palette to be used to represent groups of discrete variables. Run validColorPalettes() to obtain valid input options.

clrp_adjust

Named character vector or NULL. If character, it adjusts the color palette that is used to represent the groups. Names of the input vector must refer to the group and the respective named element denotes the color with which to represent the group.

test_groupwise

Character value or NULL. Specifies the groupwise statistical test to be conducted. If character, one of 'anova', 'kruskal.test'. If set to NULL the testing is skipped.

test_pairwise

Character value or NULL. Specifies the pairwise statistical test to be conducted. If character, one of 't.test', 'wilcox.test'. If set to NULL the testing is skipped.

ref_group

Character value or NULL. Specifies the reference group against which all other groups are compared in the test denoted in test_groupwise is conducted. If set to NULL the first group found is taken.

step_increase

Numeric value. Denotes the increase in fraction of total height for every additional comparison to minimize overlap.

vjust

Numeric value. Denotes the relative, vertical position of the results of the test denoted in test.groupwise. Negative input highers, positive input lowers the position.

display_facets

Logical value. If set to TRUE the plot is split via ggplot2::facet_wrap() such that each variable gets it's own subplot.

scales

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.

ncol

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

display_points

Logical value. If set to TRUE points are used additionally to display the results.

pt_alpha

Numeric value. Specifies the degree of transparency of all points.

pt_clr

Character value. Specifies the color of all points.

pt_size

Numeric value. Specifies the size of all points.

verbose

Logical. If set to TRUE informative messages regarding the computational progress will be printed.

(Warning messages will always be printed.)

...

Additional arguments given to the respective ggplot2::geom_<plot_type>() function. E.g. plotViolinplot() relies on ggplot2::geom_violin().


kueckelj/celltracer documentation built on June 2, 2021, 6:37 a.m.