简体   繁体   中英

Plotting topic prevelance for each group [Structural Topic Modeling R]

Community,

I have a question regarding the STM package for R and hope that you can help me find an answer.

In figure 7 of the vignette the authors present a graph, where the topic prevalence (for topic 7) over time can be seen. Is it possible to plot the same graph by adding two further lines: one for liberal and one for conservative?

Liberal and conservative are attributes of the variable "rating"

The plot in figure 7 shows you the topic proportion of one topic (in this case topic 7) over a time span of January 2008 to December 2008. Basically, this graph shows you how your topic is distributed over a specific time frame. You can plot other topics in this graph, so yes, you can add more lines, but you cannot add a variable, like liberal/conservative, to plot in this graph.

Also, you might want to have a look at this -- it would be useful to add a reproducible example for clarity

How to make a great R reproducible example

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM