Package: cosmic
Title: Conditional Ordinal Stereotype Model for Incident-Level
        Comparison
Version: 0.5
Authors@R: 
    person("Greg", "Ridgeway", , "gridge@upenn.edu", role = c("aut", "cre"))
Description: Implements the Conditional Ordinal Stereotype Model for
        Incident-Level Comparison (COSMIC), a method for analyzing
        ordinal outcomes observed across multiple actors within shared
        events. The model uses a conditional likelihood to remove
        event-level confounding and estimate actor-specific
        propensities relative to their peers. Efficient computation is
        achieved via a dynamic programming algorithm for the
        Poisson-multinomial normalization term, enabling scalable
        estimation with Markov chain Monte Carlo. The package provides
        tools for data preparation, model fitting using Stan, and
        extraction of posterior summaries for comparative inference.
        Estimation of police officer propensity to escalate force is
        the primary motivation for the model. For more details see
        Ridgeway (2026) "A Conditional Ordinal Stereotype Model to
        Estimate Police Officers’ Propensity to Escalate Force"
        <doi:10.1080/01621459.2025.2597050>.
License: MIT + file LICENSE
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.3.3
Depends: R (>= 4.1.0)
Suggests: arrangements, cmdstanr (>= 0.9.0), future, future.apply,
        ggplot2, kableExtra, knitr, MASS, progressr, rmarkdown,
        testthat (>= 3.0.0), xtable
Additional_repositories: https://stan-dev.r-universe.dev
Config/testthat/edition: 3
VignetteBuilder: knitr
Imports: dplyr, posterior, stats
Repository: https://gregridgeway.r-universe.dev
Date/Publication: 2026-10-17 20:21:43 UTC
RemoteUrl: https://github.com/gregridgeway/cosmic
RemoteRef: HEAD
RemoteSha: 54704d9f934cbf22af9b648347e4e12e6ae935f2
NeedsCompilation: no
Packaged: 2026-10-17 22:15:03 UTC; root
Author: Greg Ridgeway [aut, cre]
Maintainer: Greg Ridgeway <gridge@upenn.edu>
