Learn R Programming

diffobj (version 0.3.6)

auto_context: Configure Automatic Context Calculation

Description

Helper functions to help define parameters for selecting an appropriate context value.

Usage

auto_context(
  min = getOption("diffobj.context.auto.min"),
  max = getOption("diffobj.context.auto.max")
)

Value

S4 object containing configuration parameters, for use as the

context or parameter value in diff*

methods

Arguments

min

integer(1L), positive, set to zero to allow any context

max

integer(1L), set to negative to allow any context

Examples

Run this code
## `pager="off"` for CRAN compliance; you may omit in normal use
diffChr(letters, letters[-13], context=auto_context(0, 3), pager="off")
diffChr(letters, letters[-13], context=auto_context(0, 10), pager="off")
diffChr(
  letters, letters[-13], context=auto_context(0, 10), line.limit=3L,
  pager="off"
)

Run the code above in your browser using DataLab