chi_square_test
Perform a chi-square test of independence to assess whether two categorical variables are statistically associated or independent.
Instructions
Chi-square test of independence between two categorical columns. Tests whether two categorical variables are statistically associated or independent. Example: chi_square_test(col_a="CargoType", col_b="ProductCode")
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"col_a": "<col_a>",
"col_b": "<col_b>"
},
"name": "chi_square_test"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| col_a | Yes | ||
| col_b | Yes | ||
| df_name | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |