| Title: | Classical Cultural Consensus Analysis |
|---|---|
| Description: | Implements classical cultural consensus analysis with formal, informal, and covariance agreement models, 'UCINET'-aligned minimum-residual factor extraction, competence estimation, and answer-key estimation. Based on the classical framework of Romney, Weller, and Batchelder (1986) <doi:10.1525/aa.1986.88.2.02a00020>, Romney, Batchelder, and Weller (1987) <doi:10.1177/000276487031002003>, and Weller (2007) <doi:10.1177/1525822X07303502>. |
| Authors: | Werner Hertzog [aut, cre] |
| Maintainer: | Werner Hertzog <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.1.0 |
| Built: | 2026-05-20 13:45:25 UTC |
| Source: | https://github.com/cran/Romney |
Compute respondent-by-respondent agreement matrices for the formal, informal, and covariance consensus models.
agreement_formal(data, n_answers = NULL) agreement_informal(data) agreement_covariance(data, prior = 0.5)agreement_formal(data, n_answers = NULL) agreement_informal(data) agreement_covariance(data, prior = 0.5)
data |
A respondent-by-item matrix or data frame. |
n_answers |
Number of possible answers for the formal model. |
prior |
Prior proportion of true items for the covariance model. |
A square agreement matrix.
Estimate the most likely answer key under the formal consensus model.
answerkey_formal(data, competence, prior = NULL, answer_levels = NULL)answerkey_formal(data, competence, prior = NULL, answer_levels = NULL)
data |
A respondent-by-item matrix or data frame. |
competence |
Numeric competence scores, one per respondent. |
prior |
Optional prior distribution over answer levels. |
answer_levels |
Optional ordered vector of allowable answer levels. |
A list with key, probabilities, and levels.
Run a cultural consensus analysis using UCINET-aligned minimum-residual factor extraction for the consensus eigensystem.
consensus( data, cultures = 1, method = c("formal", "informal", "covariance"), prior = 0.5, return_answer_key = TRUE )consensus( data, cultures = 1, method = c("formal", "informal", "covariance"), prior = 0.5, return_answer_key = TRUE )
data |
A respondent-by-item matrix or data frame. |
cultures |
Number of latent cultures to extract. |
method |
One of |
prior |
Prior proportion of true items for the covariance model. |
return_answer_key |
Whether to estimate the answer key for the formal model. |
An object of class romney_consensus.
Simulate respondent-by-item response data for the formal consensus model.
simulate_consensus_data( n_respondents, n_questions, n_answers = 2, competence = 0.7, seed = NULL )simulate_consensus_data( n_respondents, n_questions, n_answers = 2, competence = 0.7, seed = NULL )
n_respondents |
Number of respondents. |
n_questions |
Number of questions/items. |
n_answers |
Number of possible answers per item. |
competence |
Scalar or vector of respondent competences. |
seed |
Optional random seed. |
A list with responses, key, and competence.