Skip to content

modyreturn/Python-MatPlotLib-Tutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

import matplotlib.pyplot as plt import numpy as np

print("Studying MatPlotLib Module")

xpoints = np.array([0, 2, 4, 6, 8,10, 12,14, 16, 18, 20]) ypoints = np.array([1, 3, 5, 3, 7, 9, 5, 7, 9, 11, 9])

plt.plot(xpoints, ypoints, "o-.b", ms = 7, mec = "c", mfc = "k" ) #formating the line chart.

plt.savefig("Figure01.png") plt.show()

xpoints = np.array([0, 4, 2, 8, 6,10, 12,14]) ypoints = np.array([1, 3, 5, 3, 7, 9, 5, 7])

plt.plot(xpoints, "o-b", ms = 10, mec = "r", mfc = "b" ) #formating X-axis plt.plot(ypoints, 'o--y', ms = 10, mec = '#4CAF50', mfc = '#4CAF50') #formating Y-axis

plt.savefig("Figure02.png") plt.show()

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published