import numpy as np
import matplotlib.pyplot as plt
x = np.linspace(0,2,100)
y = np.power(np.sin(x - 2), 2) * np.exp(-np.power(x, 2))
f, ax=plt.subplots(1, 1, figsize=(5,4))
ax.plot(x, y)
ax.set_xlim((0, 2))
ax.set_ylim((0, 2))
ax.set_xlabel('x label')
ax.set_ylabel('y label')
ax.set_title('11-1')
plt.tight_layout()
plt.plot(x, y)
plt.show()
import numpy as np
import matplotlib.pyplot as plt
X = np.random.random((20,10))
b = np.random.randn(10, 1)
z = np.random.normal(size = (20,1))
Y = np.dot(X, b)