modelplot: Plot results of t-test, ANOVA or TANOVA modeling functions

Description Usage Arguments Value Methods (by class) See Also

View source: R/plots.R

Description

modelplot is a generic function for plotting arrayTtest, arrayAnova, or tanova objects, each produced by the corresponding function.

modelplot.default plots the result of the arrayTtest or arrayAnova function.

modelplot.tanova plots the result of the tanova function.

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
modelplot(...)

## Default S3 method:
modelplot(
  results,
  what = c("statistic", "p-value"),
  type = c("corrected", "uncorrected"),
  pcrit = c(0.001, 0.01, 0.05),
  grid = NULL,
  wrap = NULL,
  time_label = "Time (ms)",
  channel_label = "Channels",
  raster = TRUE,
  cluster_order = FALSE,
  low = scales::muted("blue"),
  mid = "white",
  high = scales::muted("red"),
  midpoint = 0,
  ...
)

## S3 method for class 'tanova'
modelplot(
  results,
  what = c("statistic", "p-value"),
  type = c("corrected", "uncorrected"),
  grid = NULL,
  wrap = NULL,
  time_label = "Time (ms)",
  ...
)

Arguments

...

arguments passed to extract; e.g. use arguments 'time_window' and 'term' to display only a subset of the results

results

a list; the return value of the corresponding modeling functions

what

a character string or vector indicating what should be plotted: only the test statistics ("statistic"), only the p-values ("p-values"), or both (default). The names can be abbreviated.

type

display "corrected" (default) or "uncorrected" statistics or p-values. The names can be abbreviated.

pcrit

numeric vector of significancy limits (default: 0.001, 0.01, 0.05) for highlighting significant areas

grid

character vector or formula defining the layout of panels

wrap

character vector or formula defining the dimension which separates panels (only considered if grid is NULL)

time_label

character string; the label of the x (time) axis (default: "Time (ms)")

channel_label

character string; the label of the y (channel) axis default: "Channels")

raster

use raster image (TRUE, default) or not (FALSE)

cluster_order

logical; if TRUE, channels are ordered with hierarchical agglomerative clustering (default: FALSE)

low

colour for low/mid/high end of gradient, respectively

mid

colour for low/mid/high end of gradient, respectively

high

colour for low/mid/high end of gradient, respectively

midpoint

the midpoint (in data value) of the diverging scale (default: 0)

Value

A ggplot object or a list of such objects

Methods (by class)

See Also

See the examples for arrayAnova and tanova


tdeenes/eegR documentation built on April 19, 2021, 4:17 p.m.