Package index
Families for paired counts
Constructors for the bipois and binegbin families, which model a pair of counts by trivariate reduction with Poisson or negative-binomial components. Each family has a second constructor for partially paired designs, listed below, and the two constructors of a family share a likelihood and the post-processing methods.
-
bipois()bipois_stanvars()log_lik_bipois()posterior_predict_bipois()posterior_epred_bipois() - Joint bivariate-Poisson custom family for brms
-
binegbin()binegbin_stanvars()log_lik_binegbin()posterior_predict_binegbin()posterior_epred_binegbin() - Joint bivariate custom family with negative-binomial components for brms
Partially paired designs
Constructors for partially paired designs, in which source 1 has missing values. On an unpaired row, the likelihood term is the marginal probability of y2, so the row informs the shared component and the exclusive component of source 2.
-
bipois_partialobs()bipois_partialobs_stanvars() - Joint bivariate-Poisson family for partially observed pairs
-
binegbin_partialobs()binegbin_partialobs_stanvars() - Joint bivariate family with negative-binomial components for partially observed pairs
Prediction and imputation
Draws and expectations of both counts together, and of y1 given the recorded y2. The functions conditional on y2 impute y1 on the unpaired rows of a fit from bipois_partialobs() or binegbin_partialobs().
-
posterior_predict_y1_and_y2()posterior_epred_y1_and_y2() - Draws and expectations of both counts from the joint model
-
posterior_predict_y1_given_y2()posterior_epred_y1_given_y2() - Draws and expectations of y1 given y2
Congruence–bias coordinates
Conversion between the native parameters and the congruence–bias coordinates (the midpoint of the two expected counts, the congruence, and the source bias), and the brms formula for a model in the coordinates.
-
mfd_to_dpars() - Convert from the congruence–bias parameterisation to native parameters
-
dpars_to_mfd() - Convert from native parameters to the congruence–bias parameterisation
-
bf_mfd() - Build a brms formula in the congruence–bias parameterisation
Simulation
Random generation of paired counts from the generating model of the bipois and binegbin families, with the shared and source-exclusive components of each pair.
-
rbicount() - Random generation of paired counts