is it possible to do the following (dict is data for the first row index):
dict={'col1':1,'col2':[1,2],'col3':'str'}
nm=pd.DataFrame(dict,index=['new line'])
I expect to receive a data frame looking like:
nm
col1 col2 col3
new line 1 [1,2] str
with the values in col2 of type list, but instead I receive the following error:
ValueError: could not broadcast input array from shape (2) into shape (1)
Thanks!