Generate counts for the most frequent n-grams in text.

count_ngram(
df,
text_var = Message,
n = 2,
top_n = 50,
min_freq = 10,
hashtags = FALSE,
mentions = FALSE,
clean_text  = TRUE
)

## Arguments

df A dataframe. The variable containing the text. The number of terms to include in the n-gram. E.g. 2 produces a bi-gram. The number of n-grams to include. The minimum number of times an n-gram must be observed to be included. Should hashtags be included in the n-grams? Should mentions be included in the n-grams? Should the text variable be cleaned?

## Value

A list containing a summary table and a tidygraph object suitable for a network visualisation.