Learn R Programming

qdap (version 2.3.0)

check_spelling_interactive.character: Check Spelling

Description

View character check_spelling_interactive.

Usage

# S3 method for character
check_spelling_interactive(text.var, range = 2,
  assume.first.correct = TRUE, click = TRUE, method = "jw",
  dictionary = qdapDictionaries::GradyAugmented, parallel = TRUE,
  cores = parallel::detectCores()/2, n.suggests = 8, ...)

Arguments

text.var

A character object, specifically a text vector of character strings.

range

An integer of length 1 to use as a range for number of characters, beyond the number of characters of a word not found in the dictionary, to initially limit dictionary size and thus time to find a suggested replacement term. This may be expanded if no suitable suggestion is returned.

assume.first.correct

logical. If TRUE it is assumed that the first letter of the misspelled word is correct. This reduces the dictionary size, thus speeding up computation.

click

logical. If TRUE the interface is a point and click GUI. If FALSE the interface is command line driven.

method

Method for distance calculation. The default is "jaccard". It is assumed that smaller measures indicate closer distance. Measures that do not adhere to this assumption will result in incorrect output (see stringdist for details).

dictionary

A character vector of terms to search for. To reduce overhead it is expected that this dictionary is lower case, unique terms.

parallel

logical. If TRUE attempts to run the function on multiple cores. Note that this may not mean a speed boost if you have one core or if the data set is smaller as the cluster takes time to create.

cores

The number of cores to use if parallel = TRUE. Default is half the number of available cores.

n.suggests

The number of terms to suggest. In the case of a tie (multiple terms have the same distance from misspelled word) all will be provided. Dictionary reduction may result in less than n.suggests suggested terms.

ignored

Details

character Method for check_spelling_interactive