crosstab
Cross-tabulates two categorical columns to reveal relationships, with optional normalization to percentages for proportional analysis.
Instructions
Cross-tabulation of two categorical columns. Optional normalization (percentages). Understand relationships between two categorical variables. Set normalize=True to see percentages instead of raw counts. Example: crosstab(index_col="City", columns_col="Category", normalize=True)
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": {
"index_col": "<index_col>",
"columns_col": "<columns_col>"
},
"name": "crosstab"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| df_name | No | ||
| index_col | Yes | ||
| normalize | No | ||
| columns_col | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |