I would like to change so `True = False` or more exact change so `True = 0` and `False = 1` is there a way to do this?

I have a `dataframe` and would like to `df.groupby('country',as_index=False).sum()` and see how many `False` values there is in each country

I have tried `df['allowed'] = --df['allowed']` (allowed is the column with `True` and `False` values) to swap them but it didn't work