0
Hello, I would like the figures for the y-axis to appear alongside the points on the graph. Thanks in advance!
plt.figure(figsize = (16,8))
plt.xticks(rotation = 90)
sns.lineplot(x = dados_corona.index, y = 'Confirmados', data = dados_corona, marker = 'o', color = 'black')
sns.lineplot(x = dados_corona.index, y = 'Mortes', data = dados_corona, color = 'red', marker = 'o')
plt.title('Dias de infecção X Casos confirmados / Mortes - COVID-19', color = 'red')
plt.ylabel('Casos confirmados / Mortes', color = 'red')
plt.xlabel('Dias de infecção', color = 'red')
plt.yscale('log') #coloca o eixo y em escala logaritmica
plt.show()
The current result is the following graph:
Maybe the answer to this question can help you https://stackoverflow.com/questions/46027653/adding-labels-in-x-y-scatter-plot-with-seaborn
– ricardogobbo
Use
plt.text
https://matplotlib.org/3.1.1/api/_as_gen/matplotlib.pyplot.text.html– darcamo