Last active
September 5, 2018 11:52
-
-
Save fcunhaneto/b6a6c55072c7b4bf431750a5179c86e2 to your computer and use it in GitHub Desktop.
Inserindo titulo e legendas.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import matplotlib.pyplot as plt | |
""" | |
Inserindo titulo e legendas | |
""" | |
x = np.arange(1, 11) | |
print(x) | |
plt.figure(figsize=(6, 4)) | |
plt.plot(x, 2*x, color='#17a589', label='f(x) = 2x') # green | |
plt.plot(x, x/2, color='red', label='f(x) = x/2') | |
plt.plot(x, x+3, color='#f4d03f', label='f(x) = x + 3') # yellow | |
plt.grid(True) | |
plt.title('Retas Simples') | |
plt.legend() | |
plt.savefig('reta-titulo-legendas.png') | |
plt.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment