textplot_influence: Influence plot for text scaling models

Description Usage Arguments Author(s) See Also Examples

View source: R/textplot_influence.R

Description

Plot the results of a fitted scaling model, from (e.g.) a predicted textmodel_affinity model.

Usage

1
textplot_influence(x, n = 30, ...)

Arguments

x

the object output from influence() run on the fitted or predicted scaling model object to be plotted

n

the number of features whose influence will be plotted

...

additional arguments passed to plot()

Author(s)

Patrick Perry and Kenneth Benoit

See Also

textmodel_affinity()

influence.predict.textmodel_affinity()

Examples

1
2
3
tmod <- textmodel_affinity(quanteda::data_dfm_lbgexample, y = c("L", NA, NA, NA, "R", NA))
pred <- predict(tmod)
textplot_influence(influence(pred))

quanteda.textmodels documentation built on April 6, 2021, 9:06 a.m.