plot_word_topic_series: Plot word frequencies within topics over time

plot_word_topic_seriesR Documentation

Plot word frequencies within topics over time

Description

Displays the allocation among topics of a given word. This is a useful diagnostic for models of corpora that are spread over time. The Gibbs sampling state must be loaded. Many analogous plots that condition word weights on two or more variables are possible; see the package vignette for a description of how they can be constructed.

Usage

plot_word_topic_series(m, word, n = n_topics(m), breaks = "years")

Arguments

m

dfr_lda object

word

a word found in the model vocabulary

n

number of topics to include in plot. The cut is made by ranking topics according to their overall totals of word.

breaks

time periodicity of the series

Value

A ggplot object.


agoldst/dfrtopics documentation built on July 15, 2022, 4:13 p.m.