plot.dimRandoTest: Quick & easy option to plot result from dimRandoTest()

View source: R/plot.dimRandoTest.R

plot.dimRandoTestR Documentation

Quick & easy option to plot result from dimRandoTest()

Description

This creates a bar plot (using base R graphics) showing the main results from a test for successful vignette attribute randomization. Shown are p-values per vignette attribute based on chi-squared tests or one-way ANOVA estimations (see ?dimRandoTest for details). For custom (and publication-quality) graphs, export result as data.frame with as.data.frame().

Usage

## S3 method for class 'dimRandoTest'
plot(
  x,
  showsig = NULL,
  lcol = NULL,
  ltype = NULL,
  siglev = NULL,
  margins = NULL,
  ...
)

Arguments

x

dimRandoTest object

showsig

Show vertical line to indicate sign. threshold? (optional, default=T)

lcol

Color of sign. threshold line (optional, changes 'col' argument for abline()).

ltype

Type of sign. threshold line (optional, changes 'lty' argument for abline()).

siglev

Significance threshold (optional, the default is 0.05).

margins

Plot margins (optional; changes par(mar())); must be a numeric vector of length 4.

...

ignored.

Examples

## Not run: 
result <- dimRandoTest(data=experimentdata,
attributes=c("age","nationality","gender"),
resvar = "respondent_gender",
vartype = "categorical")

plot(result)

## End(Not run)


cknotz/conjointdatachecks documentation built on Feb. 11, 2023, 12:04 a.m.