Here is a list of values, I would like my dataframe to have :
cols=['USA','CAN','UK','DEN']
My current df:
| ID | USA | DEN | VEN | NOR|
| 98 | 1 | 0 | 1 | 1 |
| 99 | 0 | 1 | 0 | 0 |
I want to check if my existing df has all the values in the list as columns, if not then create those columns and fill then with 0 like:
| ID | USA | DEN | VEN | NOR| CAN | UK|
| 98 | 1 | 0 | 1 | 1 | 0 | 0 |
| 99 | 0 | 1 | 0 | 0 | 0 | 0 |