inst/doc/CornerCases.R

## ----exdisj-------------------------------------------------------------------
library("wrapr")

X <- 1
Y <- 2

let(
 c(),
  debugPrint = TRUE,
  X + Y
)

let(
 c(),
  debugPrint = TRUE,
  subsMethod = 'langsubs',
  X + Y
)

let(
 c(),
  debugPrint = TRUE,
  subsMethod = 'stringsubs',
  X + Y
)

let(
 c(),
  debugPrint = TRUE,
  subsMethod = 'subsubs',
  X + Y
)

## ----exswap-------------------------------------------------------------------
library("wrapr")

X <- 1
Y <- 2

let(
  c(X='Y', Y='X'),
  debugPrint = TRUE,
  X + Y
)

let(
  c(X='Y', Y='X'),
  debugPrint = TRUE,
  subsMethod = 'langsubs',
  X + Y
)

let(
  c(X='Y', Y='X'),
  debugPrint = TRUE,
  subsMethod = 'stringsubs',
  X + Y
)

let(
  c(X='Y', Y='X'),
  debugPrint = TRUE,
  subsMethod = 'subsubs',
  X + Y
)

Try the wrapr package in your browser

Any scripts or data that you put into this service are public.

wrapr documentation built on Aug. 20, 2023, 1:08 a.m.