Skip to content

Commit

Permalink
add the references for numpy and matplotlib at 4.2 and 4.3
Browse files Browse the repository at this point in the history
  • Loading branch information
WilliamWu96 committed Oct 10, 2022
1 parent fb74619 commit cad7c3c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
8 changes: 8 additions & 0 deletions Part_1/4.2.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
import numpy as np
import matplotlib.pyplot as plt
"""
References for numpy and matplotlib:
- numpy:
https://numpy.org/doc/stable/reference/arrays.ndarray.html
https://numpy.org/doc/stable/reference/index.html
- matplotlib:
https://matplotlib.org/3.5.1/api/_as_gen/matplotlib.pyplot.html
"""


x = np.arange(100)
Expand Down
10 changes: 9 additions & 1 deletion Part_1/4.3.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
import numpy as np
import matplotlib.pyplot as plt
"""
References for numpy and matplotlib:
- numpy:
https://numpy.org/doc/stable/reference/arrays.ndarray.html
https://numpy.org/doc/stable/reference/index.html
- matplotlib:
https://matplotlib.org/3.5.1/api/_as_gen/matplotlib.pyplot.html
"""

xdata = 7 * np.random.random(100)
ydata = np.sin(xdata) + 0.25 * np.random.random(100)
Expand All @@ -16,4 +24,4 @@
ax.set_zlabel('z')
# Save figure
plt.savefig('3d_scatter.png', dpi = 300, bbox_inches = 'tight',
pad_inches = 0);
pad_inches = 0)

0 comments on commit cad7c3c

Please sign in to comment.