txt_count_words: Count the number of spaces occurring in text
Description
The C++ doc2vec functionalities in this package assume words are either separated
by a space or tab symbol and that each document contains less than 1000 words.
This function calculates how many words there are in each element of a character vector by counting
the number of occurrences of the space or tab symbol.
Usage
txt_count_words(x, pattern = "[ \t]", ...)
Arguments
x
a character vector with text
pattern
a text pattern to count which might be contained in x. Defaults to either space or tab.