0
votes

Currently in Excel i have a column of IDs and a column of corresponding information in format: {'col1': 'num1', 'col2': 'num2', 'col3': 'num3'}

I need to parse the data and then return a table in excel, keeping the column of IDs and adding col1, col2, and col3 with num1, num2, and num3 in the cells below.

current format

required format

Any help much appreciated

1

1 Answers

0
votes

Looks like your data is in JSON format. You may want to do is open an Excel file (workbook), read it, use a json library to parse the values in structures, then write it in another Excel file.

To read/write Excel files, you could use xlrd+xlwt or openpyxl.
To read/write JSON data, you should use the standard library.