spss_import_csv
Convert CSV to SPSS .sav format directly, no IBM SPSS installation required.
Instructions
Convert a CSV file to SPSS .sav format directly using pandas + pyreadstat — no IBM SPSS Statistics installation required. Much faster than going through SPSS syntax because it bypasses the SPSS engine entirely. Saves the .sav file next to the CSV by default, or to a custom output_path.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| csv_path | Yes | Full path to the source CSV file. | |
| encoding | No | CSV file encoding (default: utf-8). | utf-8 |
| delimiter | No | Column delimiter (default: comma). | , |
| output_path | No | Destination .sav file path. Defaults to the same directory as the CSV with .sav extension. | |
| column_labels | No | Mapping of column names to SPSS variable labels, e.g. {"age": "Age of respondent"}. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |