I have a dataset of corona virus which looks something like this
day month cases deaths country
3 5 10 1 USA
4 5 12 2 USA
it has multiple entries for each country for different days, I made it filter out so it only gets the data from 28th of May now I want to make a graph for every country with how many cases they have use pandas and matploitlib
However it's not working properly
when I use
import pandas as pd
import matplotlib.pyplot as plt
df = pd.read_excel("covid.xlsx")
print(df.columns.tolist())
df.loc[(df.day == 28) & (df.month==5), :].plot.line(x='countriesAndTerritories', y='deaths')
plt.show()
The code executes but only shows 5 countries and the countriesAndTerritories is on the x axis, when I switch around x='countriesAndTerritories', y='deaths' I get TypeError: no numeric data to plot
This is a reference of what I want: https://qap.ecdc.europa.eu/public/single/?appid=f818d019-18c5-41e0-99e6-bd2b7f6f17b5&obj=3d471628-9a6e-4938-95da-0cba933925ca&opt=nointeraction&select=clearall (europe's data visualization)
