I have a dataframe
`data = np.array([['val1', 'val2'], ['val3', 'val4']]) dataFrame = pd.DataFrame(data, columns = ['key1', 'key2'])
I need to conver it into json.
By default the outout looks like:
{"key1":{"0":"val1","1":"val3"},"key2":{"0":"val2","1":"val4"}}
`
I need it in the following layout.
{'key1':['val1','val2'],'key2':['val3','val4']}
I have looked up the option on pandas and none of them give me the desired output.