speaker_odds {stylest2}R Documentation

Internal stylest2 function to predict log odds of speakership across texts.

Description

Internal stylest2 function to predict log odds of speakership across texts.

Usage

speaker_odds(log_weights, pred_docs_dfm, pred_docs_ntoken, speakers)

Arguments

log_weights

The logged author-level term weights from a stylest2 model.

pred_docs_dfm

A document-feature matrix for the texts to be predicted.

pred_docs_ntoken

A vector, the number of tokens in each prediction document.

speakers

The speaker labels for pred_docs_dfm rows.


[Package stylest2 version 0.1 Index]