Skip to content

Commit

Permalink
Sampling tests
Browse files Browse the repository at this point in the history
  • Loading branch information
davidenitti committed Nov 14, 2016
1 parent ea79874 commit 7fa61e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sampling/nnleastsquare.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def weights(X, oldX, oldW):

if count % 1 == 0:

ax.plot(X_plot, normtarget(X_plot), label='normalized f(x)')
ax.plot(X_plot, normtarget(X_plot), label='normalized f(x) = optimal proposal')
ax.plot(X_plot, target(X_plot), label='f(x) to integrate')
pr = proposal(Centroids, W, Centroids, bandwidth)
ax.scatter(X, WX / 10., s=10, marker='x', color='red', label="weight")
Expand All @@ -96,7 +96,7 @@ def weights(X, oldX, oldW):
ax.plot(Centroids, -0.01 - 0.1 * np.random.random(Centroids.shape[0]), '+k')

ax.set_xlim(-0.01, 1.01)
ax.set_ylim(-0.2, 2.5)
ax.set_ylim(-0.2, 3)
plt.draw()
plt.pause(0.1)
ax.clear()

0 comments on commit 7fa61e9

Please sign in to comment.