Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

TypeError: Can only append a dict if ignore_index=True

import pandas as pd
df = pd.DataFrame([[1, 2], [3, 4]], columns=list('AB'), index=['x', 'y'])
dict_ ={"A":5,"B":9}
df =df.append(dict_,ignore_index=True)
print(df)
Source by fixexception.com #
 
PREVIOUS NEXT
Tagged: #Can #append #dict
ADD COMMENT
Topic
Name
1+3 =