Description Usage Arguments Value Examples
View source: R/stylest_speaker_odds.R
Computes the mean log odds of the most likely speaker of each
text over pairs of the speaker of a text and every other speaker in the
stylest_model
.
1 | stylest_odds(model, text, speaker, prior = NULL)
|
model |
|
text |
Text vector. May be a |
speaker |
Vector of speaker labels. Should be the same length as
|
prior |
Prior probability of speakers. Uses equal prior if |
A S3 stylest_odds
object containing: a
stylest_model
object; vector of mean log odds that each actual
speaker (compared with other speakers in the corpus) spoke their
corresponding texts in the corpus; vector of SEs of the log odds
1 2 3 4 | data(novels_excerpts)
speaker_mod <- stylest_fit(novels_excerpts$text, novels_excerpts$author)
stylest_odds(speaker_mod, novels_excerpts$text, novels_excerpts$author)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.