Skip to content

Commit 0bb0ad1

Browse files
michaelosthegealoctavodia
authored andcommitted
sets ylim to make nicer density plots (#2617)
see #2616
1 parent 0bb5211 commit 0bb0ad1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pymc3/plots/kdeplot.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ def kdeplot(values, label=None, shade=0, ax=None, kwargs_shade=None, **kwargs):
3838
density, l, u = fast_kde(values)
3939
x = np.linspace(l, u, len(density))
4040
ax.plot(x, density, label=label, **kwargs)
41+
ax.set_ylim(0)
4142
if shade:
4243
ax.fill_between(x, density, alpha=shade, **kwargs_shade)
4344
return ax

0 commit comments

Comments
 (0)