stats.chisq_test

Pearson's chi-squared test of independence between two categorical columns.

  • Kind: standard
  • Network: no

Inputs🔗

NameTypeDescription
datafile (CSV)Input table containing the two categorical columns.
columnstringName of the first categorical column.
bystringName of the second categorical column to test for independence against the first.
correctbooleanWhether to apply Yates' continuity correction (only affects 2x2 tables). Defaults to true.

Outputs🔗

NameTypeDescription
resultjsonTest results - chi-squared statistic, degrees of freedom, p-value, and the observed contingency table.

Example🔗

- id: 01890000-0000-0000-0000-000000000404
  name: stats.chisq_test
  inputs:
    - 01890000-0000-0000-0000-000000000000
  args:
    column: "ownership"
    by: "forest_type"
    correct: true