human
How can I "unpivot" specific columns from a pandas DataFrame?
assistant
Here is some code to unpivot first 2 columns into new columns 'year' and 'value' from a pandas dataframe `x`

pd.melt(x, id_vars=['farm', 'fruit'], var_name='year', value_name='value')

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.