I have a dataset and I want to drop all the rows that are now in my condition. This is my code:
covid = covid.drop(covid[covid.Country != "South Africa"].index)
I can drop all the rows where shouth africa is not the country, but i want to keep other countries apart from south africa, eg. South africa, UK, USA, India...
I have tryed:
covid = covid.drop(covid[covid.Country != "South Africa" and "UK"].index)
covid = covid.drop(covid[covid.Country != "South Africa" & "UK"].index)
covid = covid.drop(covid[covid.Country != "South Africa", "UK"].index)
but none of these work.