Learn R Programming

emmeans (version 1.10.5)

emm_example: Run or list additional examples

Description

This function exists so as to provide cleaner-looking examples in help files when it must be run conditionally on another package. Typically we want to run the code (run = TRUE is the default), or otherwise just list it on the console (list = TRUE).

Usage

emm_example(name, run = !list, list = FALSE, ...)

Arguments

name

Character name of file to run. We look for a file with this name (with ".R" appended) in the system files provided with emmeans.

run

Logical choosing whether or not to run the example code

list

Logical choosing whether or not to list the example code

...

Used only by the developer

Examples

Run this code
# List an example
emm_example("qdrg-biglm", list = TRUE)

# Run an example
if (require(biglm))
    emm_example("qdrg-biglm")

Run the code above in your browser using DataLab