I want to create a dictionary where the key is a state name and the value is the sum of all the count corresponding to the state.
Example from dataFrame
State Count
California 100
Colorado 100
California 54
Colorado 9254
I was trying to use the following, but not sure how to include a sum function inside this, also not sure if I should be using a zip method here:
df_dict = dict(zip(df.State, df.Count))
print df_dict