ppcheckPLMIX_single: Posterior predictive check for a mixture of Plackett-Luce...

View source: R/PLMIXfunctions.R

ppcheckPLMIX_singleR Documentation

Posterior predictive check for a mixture of Plackett-Luce models

Description

Compute predictive posterior p-values based on top item and paired comparison frequencies to assess the goodness-of-fit of a Bayesian mixtures of Plackett-Luce models for partial orderings.

Usage

ppcheckPLMIX_single(
  pi_inv,
  G,
  MCMCsampleP,
  MCMCsampleW,
  top1 = TRUE,
  paired = TRUE
)

Arguments

pi_inv

An object of class top_ordering, collecting the numeric N\timesK data matrix of partial orderings, or an object that can be coerced with as.top_ordering.

G

Number of mixture components.

MCMCsampleP

Numeric L\timesG*K matrix with the MCMC samples of the component-specific support parameters.

MCMCsampleW

Numeric L\timesG matrix with the MCMC samples of the mixture weights.

top1

Logical: whether the posterior predictive p-value based on top frequencies has to be computed. Default is TRUE.

paired

Logical: whether the posterior predictive p-value based on paired comparison frequencies has to be computed. Default is TRUE.

Details

In the case of partial orderings, the same missingness patterns of the observed dataset, i.e., the number of items ranked by each sample unit, are reproduced on the replicated datasets.

Value

A list of named objects:

post_pred_pvalue_top1

If top1 is TRUE, posterior predictive p-value based on top frequencies, otherwise NULL.

post_pred_pvalue_paired

If paired is TRUE, posterior predictive p-value based on paired comparison frequencies, otherwise NULL.

Author(s)

Cristina Mollica and Luca Tardella


PLMIX documentation built on July 1, 2025, 1:12 a.m.