token_permutation.all: Token Permutations - All

Description Usage Arguments Value Examples

View source: R/transform.R

Description

Collects all tokens that could result from performing any edit operation on the input token using a more efficient single-pass implementation

Usage

1
token_permutation.all(token, split = TRUE, simplify = FALSE)

Arguments

token
  • either 1 token or a pre-split set of ordered letters that make up the token

split
  • whether the input token needs to be split into individual letters or not - default = TRUE

simplify
  • whether to return a simplified vector of the token permutations, or a list containing the permutations for each separate operation (delete, replace, insert) - default = FALSE

Value

Examples

1
2
3
token_permutation.all('sometoken')
token_permutation.all(c('s','o','m','e','t','o','k','e','n'), split = FALSE)
token_permutation.all('sometoken', simplify = TRUE)

duncankmckinnon/ezRnlp documentation built on Aug. 6, 2020, 1:28 a.m.