| plot_marginal_pairwise | R Documentation |
Plot strict pairwise local-dependence follow-up using base R
plot_marginal_pairwise(
x,
diagnostics = NULL,
metric = c("exact", "adjacent"),
top_n = 20,
facet = NULL,
main = NULL,
palette = NULL,
label_angle = 45,
preset = c("standard", "publication", "compact", "monochrome"),
draw = TRUE
)
x |
Output from |
diagnostics |
Optional output from |
metric |
|
top_n |
Maximum level pairs shown. |
facet |
Optional facet name used to keep only matching pairwise rows. |
main |
Optional custom plot title. |
palette |
Optional named color overrides. Recognized names: |
label_angle |
X-axis label angle. |
preset |
Visual preset ( |
draw |
If |
This helper visualizes the strict pairwise local-dependence follow-up derived from posterior-integrated expected exact and adjacent agreement.
The "exact" view ranks level pairs by the absolute exact-agreement
standardized residual. The "adjacent" view uses the adjacent-agreement
standardized residual instead. Both are exploratory corroboration screens for
strict marginal-fit flags.
A plotting-data object of class mfrm_plot_data.
Positive bars mean the observed agreement exceeded the posterior-expected agreement for that level pair.
Negative bars mean the observed agreement fell below the posterior-expected agreement.
Red bars indicate the pair exceeded the current strict-warning threshold.
Fit with fit_mfrm() using method = "MML" for RSM / PCM.
Run diagnose_mfrm() with diagnostic_mode = "both".
Use plot_marginal_pairwise() to inspect level pairs behind pairwise
local-dependence flags.
Corroborate with legacy diagnostics, design review, and substantive interpretation before making claims.
For a plot-selection guide and a longer walkthrough, see
mfrmr_visual_diagnostics and
vignette("mfrmr-visual-diagnostics", package = "mfrmr").
diagnose_mfrm(), plot_marginal_fit(), mfrmr_visual_diagnostics
toy <- load_mfrmr_data("example_core")
fit <- fit_mfrm(
toy,
"Person",
c("Rater", "Criterion"),
"Score",
method = "MML",
quad_points = 7,
maxit = 30
)
diag <- diagnose_mfrm(fit, residual_pca = "none", diagnostic_mode = "both")
p <- plot_marginal_pairwise(diag, draw = FALSE, preset = "publication")
p$data$preset
if (interactive()) {
plot_marginal_pairwise(
diag,
metric = "adjacent",
draw = TRUE,
preset = "publication"
)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.