Re: How to modify Adaline Stochastic gradient descent

2019-03-14 Thread MRAB
On 2019-03-15 02:48, voko...@gmail.com wrote: Dear May I know how to modify my own Python programming so that I will get the same picture as refer to the attached file - Adaline Stochastic gradient descent [snip] This newsgroup is text-only, and all other attachments, including pictures, are

How to modify Adaline Stochastic gradient descent

2019-03-14 Thread vokoyov
=1) sgd1.fit(X_std, y) sgd2.fit(X_std, y) sgd3.fit(X_std, y) plt.plot(range(1, len(sgd1.cost) + 1), sgd1.cost, marker='o', linestyle='oo', label='batch=1') plt.plot(range(1, len(sgd2.cost_) + 1), np.array(sgd2.cost_) / len(y_train), mark