{
  "name": "R mosaic workflow: inputs and diagnostic checks",
  "description": "Original compilation of documented input representations, named controls and diagnostic outputs for four R functions used in a mosaic plotting workflow. Compiled across the R base, stats and graphics reference manuals; this is an API reference matrix, not empirical research data.",
  "page": "https://casrai.org/guides/mosaic-plot-in-r",
  "publisher": "CASRAI",
  "license": "https://creativecommons.org/licenses/by/4.0/",
  "dateModified": "2026-11-17T12:46:33Z",
  "temporalCoverage": null,
  "spatialCoverage": null,
  "columns": [
    {
      "name": "Function",
      "unit": "",
      "description": ""
    },
    {
      "name": "Documented input",
      "unit": "",
      "description": ""
    },
    {
      "name": "Control or output to inspect",
      "unit": "",
      "description": ""
    },
    {
      "name": "Documentation source",
      "unit": "",
      "description": ""
    }
  ],
  "rows": [
    {
      "Function": "base::table",
      "Documented input": "Cross-classifying factors or objects interpretable as factors",
      "Control or output to inspect": "useNA: no, ifany or always",
      "Documentation source": "https://stat.ethz.ch/R-manual/R-devel/library/base/html/table.html"
    },
    {
      "Function": "stats::xtabs",
      "Documented input": "Formula with optional counts on the left and grouping factors on the right",
      "Control or output to inspect": "drop.unused.levels: whether unused factor levels are dropped",
      "Documentation source": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/xtabs.html"
    },
    {
      "Function": "graphics::mosaicplot",
      "Documented input": "Contingency table or formula interface",
      "Control or output to inspect": "shade activates residual shading; type selects pearson, deviance or FT",
      "Documentation source": "https://stat.ethz.ch/R-manual/R-devel/library/graphics/html/mosaicplot.html"
    },
    {
      "Function": "stats::chisq.test",
      "Documented input": "Two-dimensional contingency count table for an independence test",
      "Control or output to inspect": "observed, expected, residuals and stdres are distinct returned fields",
      "Documentation source": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/chisq.test.html"
    }
  ],
  "sources": [
    {
      "title": "R: Cross Tabulation and Table Creation",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/base/html/table.html",
      "accessed": "2026-11-17"
    },
    {
      "title": "R: Cross Tabulation",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/xtabs.html",
      "accessed": "2026-11-17"
    },
    {
      "title": "R: Mosaic Plots",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/graphics/html/mosaicplot.html",
      "accessed": "2026-11-17"
    },
    {
      "title": "R: Pearson's Chi-squared Test for Count Data",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/chisq.test.html",
      "accessed": "2026-11-17"
    }
  ]
}