distribution

How to plot a mean line on a distplot between 0 and the y value of the mean?

别来无恙 提交于 2020-12-06 04:16:26
问题 I have a distplot and I would like to plot a mean line that goes from 0 to the y value of the mean frequency. I want to do this, but have the line stop at when the distplot does. Why isn't there a simple parameter that does this? It would be very useful. I have some code that gets me almost there: plt.plot([x.mean(),x.mean()], [0, *what here?*]) This code plots a line just as I'd like except for my desired y-value. What would the correct math be to get the y max to stop at the frequency of