wviostripchart_list: wviostripchart_list

Description Usage Arguments Examples

View source: R/MarkdownReportsDev.R

Description

Create and save violin plots as .pdf, in "OutDir". It requires (and calls) "vioplot" package. If mdlink = TRUE, it inserts a .pdf and a .png link in the markdown report, set by "path_of_report". The .png version is not created, only the link is put in place, not to overwrite previous versions.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
wviostripchart_list(
  yourlist,
  ...,
  pch = 20,
  viocoll = c(2:(length(yourlist) + 1)),
  vioborder = 1,
  bg = 1,
  col = 1,
  metod = "jitter",
  jitter = 0.25,
  main = as.character(substitute(yourlist)),
  sub = NULL,
  xlab = names(yourlist),
  ylab = "",
  incrBottMarginBy = 0,
  savefile = unless.specified("b.save.wplots"),
  w = unless.specified("b.defSize", 7),
  h = w,
  mdlink = ww.set.mdlink(),
  PNG = unless.specified("b.usepng", F)
)

Arguments

yourlist

Input list to be plotted.

...

Pass any other parameter of the corresponding plotting function(most of them should work).

pch

Define the symbol for each data point. A number 0-25 or any string between ""-s.

viocoll

Background color of each individual violing plot.

vioborder

Border color of each individual violing plot.

bg

Background color.

col

Color of the plot.

metod

Method for displaying data points to avoid overlap; either"jitter" or "stack". See stripchart().

jitter

The amount of horizontal scatter added to the individual data points (to avoid overlaps).

main

Title of the plot (main parameter) and also the name of the file.

sub

Subtitle below the plot.

xlab

X-axis label.

ylab

Y-axis label.

incrBottMarginBy

Increase the blank space at the bottom of the plot. Use if labels do not fit on the plot.

savefile

Save plot as pdf in OutDir, TRUE by default.

w

Width of the saved pdf image, in inches.

h

Height of the saved pdf image, in inches.

mdlink

Insert a .pdf and a .png image link in the markdown report, set by "path_of_report".

PNG

Set to true if you want to save the plot as PNG instead of the default PDF.

Examples

1
2
3
try.dev.off(); my.ls = list(A = rnorm(10), B = rnorm(10), C = rnorm(10));
# wviostripchart_list (yourlist = my.ls, pch = 23, viocoll = 0, vioborder = 1, sub = FALSE,
# bg = 0, col = "black", metod = "jitter", jitter = 0.1, w = 7, mdlink = FALSE)

vertesy/MarkdownReportsDev documentation built on Nov. 15, 2021, 9:59 a.m.