Description Usage Arguments Details Value

View source: R/countPatternMatches.R

Count how many matches are generated by each pattern.

1 | ```
countPatternMatches(X, patterns)
``` |

`X` |
A character vector where matches are sought. |

`patterns` |
A vector of regular expression patterns. |

This is meant to be useful when developing a vector of regexes to
apply to text. Unlike `patternappy()`

, which only finds the first
regex that matches each element of text, a text element here can match
multiple regexes. Therefore, the sum of the returned vector may not equal
the length of the input `X`

.

A integer vector of same length as `patterns`

with a count of
matches.

eamoncaddigan/patternapply documentation built on May 13, 2017, 10:56 a.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.