multiMismatch: Find fewest mismatches for multiple patterns

View source: R/leven.R

multiMismatchR Documentation

Find fewest mismatches for multiple patterns

Description

Find fewest mismatches (and position if desired) between pattern and string without allowing gaps. Could be programmed better but quick enough for now

Usage

multiMismatch(patterns, subject, drop = TRUE, ...)

Arguments

patterns

A vector of string patterns to search for in subject

subject

A single subject string to search in

drop

If TRUE return only return the first best match

...

Additional arguments for bestMismatch

Value

Three column matrix with columns minMismatch, position, pattern number

Author(s)

Scott Sherrill-Mix R@sherrillmix.com


sherrillmix/levenR documentation built on Oct. 25, 2023, 11:42 a.m.