count: count

Description Usage Arguments Value Examples

View source: R/count.R

Description

Compute frequency based text features

Usage

1

Arguments

x

a vector of strings. The strings can either be single words or longer documents.

Value

a matrix of frequency based features.

Examples

1
2
3
4
5
##count(c("i am the WALRUS", "Jerk!!", "very very good"))
                n_words n_unique_words n_chars n_unique_chars n_periods n_commas n_question n_exclamation
##i am the WALRUS       4              4      15             13         0        0          0             0
##Jerk!!                1              1       6              5         0        0          0             2
##very very good        3              2      14              8         0        0          0             0

cookm346/textfeats documentation built on April 24, 2020, 9:50 p.m.