tabulate
Compute weighted crosstabulation of survey variables to analyze relationships between categories. Use with optional filters and normalization for precise proportion comparisons.
Instructions
Compute a weighted crosstab between two variables.
Args: row_var: Variable for rows (e.g., 'educ', 'region'). col_var: Variable for columns (e.g., 'sexo', 'cohorte'). filter: Optional filter expression (e.g., "sexo == 1", "cohorte == 3"). normalize: How to normalize: 'row' (default), 'col', 'all', or 'none'. dataset: Which dataset to use (default: entrevistado).
Returns a markdown table with weighted proportions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| row_var | Yes | ||
| col_var | Yes | ||
| filter | No | ||
| normalize | No | row | |
| dataset | No | entrevistado |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |