Task: Data-transform-reshape (source dataset: Auto-Tables)

Given a table, predict what python pandas transformation may be needed on the given input table. Valid choices for transformation include: {"stack", "wide_to_long", "transpose", "pivot", "explode", "ffill", "subtitles"}. Note that each of these is a common Python Pandas operator. Some transformations can have parameters. Each transformation and its parameters are describe as follows.
 
- stack: collapse homogeneous cols into rows.
@param (int): stack_start_idx: zero-based starting column index of the homogeneous column-group.
@param (int): stack_end_idx: zero-based ending column index of the homogeneous column-group.
 
- wide_to_long: collapse repeating col-groups into rows.
@param (int): wide_to_long_start_idx: zero-based starting column index of the repeating col-groups.
@param (int): wide_to_long_end_idx: zero-based ending column index of the repeating col-groups.
 
- transpose: convert rows to columns and vice versa.
 
- pivot: pivot repeating row-groups into cols.
@param (int): pivot_row_frequency: frequency of repeating row-groups.
 
- ffill: fill structurally empty cells in tables.
@param (int): ffill_end_idx: zero-based ending column index of the columns to be filled.
 
- explode: convert composite cells into atomic values
@param (int): explode_column_idx: zero-based column index of the column to be exploded.
 
- subtitle: convert table subtitles into a column.
 
OUTPUT the predicted transformation name along with its parameters for the given INPUT table in a JSON, e.g., {"transformation": "stack", "stack_start_idx": 1, "stack_end_idx": 5}. If the input table needs multi-step transformations (e.g, ffill followed by stack), list JSON of each transformation sequentially in a list, e.g., [{"transformation": "ffill", "ffill_end_idx": 1}, {"transformation": "stack", "stack_start_idx": 1, "stack_end_idx": 5}]. No explanation is needed.

## Input:
| Percentage of students who currently use tobacco   | 6th Grade   | 7th Grade   | 8th Grade   | 9th Grade   | 10th Grade   | 11th Grade   | 12th Grade   |
|:---------------------------------------------------|:------------|:------------|:------------|:------------|:-------------|:-------------|:-------------|
| Cigarette                                          |             |             |             |             |              |              |              |
| 0                                                  | 1.1         | 2.0         | 2.4         |             |              |              |              |
| 1                                                  |             |             |             | 5.1         | 6.4          | 5.6          | 9.4          |
| Cigar                                              |             |             |             |             |              |              |              |
| 0                                                  | 1.6         | 2.0         | 4.0         |             |              |              |              |
| 1                                                  |             |             |             | 6.4         | 6.8          | 9.0          | 10.8         |
| E-Cigarette (Current Use)                          |             |             |             |             |              |              |              |
| 0                                                  | 2.8         | 5.9         | 10.3        |             |              |              |              |
| 1                                                  |             |             |             | 14.6        | 14.2         | 15.3         | 18.4         |
| E-Cigarette (Frequent Use)                         |             |             |             |             |              |              |              |
| 0                                                  | 0.5         | 0.8         | 1.4         |             |              |              |              |
| 1                                                  |             |             |             | 2.5         | 2.3          | 2.3          | 3.8          |
| Hookah                                             |             |             |             |             |              |              |              |
| 0                                                  | 2.0         | 3.3         | 5.4         |             |              |              |              |
| 1                                                  |             |             |             | 8.3         | 9.9          | 7.5          | 11.8         |
| Specialty                                          |             |             |             |             |              |              |              |
| 0                                                  | 0.8         | 1.0         | 0.9         |             |              |              |              |
| 1                                                  |             |             |             | 2.1         | 2.6          | 2.2          | 2.7          |
| Flavored Tobacco                                   |             |             |             |             |              |              |              |
| 0                                                  | 1.8         | 2.5         | 3.6         |             |              |              |              |
| 1                                                  |             |             |             | 6.9         | 7.6          | 8.1          | 9.4          |
| Smokeless                                          |             |             |             |             |              |              |              |
| 0                                                  | 1.4         | 1.5         | 2.1         |             |              |              |              |
| 1                                                  |             |             |             | 4.7         | 4.4          | 3.2          | 6.0          |
| Snus                                               |             |             |             |             |              |              |              |
| 0                                                  | 0.7         | 0.9         | 0.9         |             |              |              |              |
| 1                                                  |             |             |             | 1.6         | 1.9          | 1.7          | 2.0          |

## Output:


source: excel_file
label: operator: subtitle
operator: stack
stack_start_idx: 1
stack_end_idx: 7
alternative_label: operator: stack
stack_start_idx: 1
stack_end_idx: 7
operator: subtitle