load_data
Loads time series from Excel or CSV files and writes a .inp file for analysis, automatically detecting dates or accepting manual frequency and start settings.
Instructions
Load a time series from Excel or CSV and write a fue .inp file.
If the file has a date index (DatetimeIndex), freq and start are inferred automatically. If not, you must provide freq, start_year and start_period.
Parameters
source_path : path to .xlsx, .xls, .ods or .csv file output_inp : path for the output .inp file (e.g. "cases/IPC_ES/IPC_ES.inp") column : column name to extract (exact match or 0-based integer index) series_name : name for the series in the .inp (default: column name) sheet : sheet name for Excel (default: first sheet) freq : 1=annual, 4=quarterly, 12=monthly (0 = auto-detect from dates) start_year : start year if no date index (0 = auto-detect) start_period : start period within year if no date index (1-based)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | ||
| sheet | No | ||
| column | Yes | ||
| output_inp | Yes | ||
| start_year | No | ||
| series_name | No | ||
| source_path | Yes | ||
| start_period | No |