Skip to content

Instantly share code, notes, and snippets.

@OrangoMango
Created April 15, 2020 16:10
Show Gist options
  • Save OrangoMango/80e18411dd128d81eeb13ee514b6bf36 to your computer and use it in GitHub Desktop.
Save OrangoMango/80e18411dd128d81eeb13ee514b6bf36 to your computer and use it in GitHub Desktop.
#stayAtHome coronavirus plot with matplotlib module
import matplotlib.pyplot as plt
y = [1]
for x in range(10):
y.append(y[x]*2)
x = [x for x in range(len(y))]
plt.plot(x, y, "--ko", label="Coronavirus", color="red")
plt.plot([0,10], [560,0], label="Money", color="green")
plt.title("Coronavirus death")
plt.xlabel("time")
plt.ylabel("death/euro")
plt.legend()
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment