### Documentation sample plot for Rice distribution docs (#3862)

* Added example plot for the Rice distribution.

* Updated for scipy rice distribution convention.

* Reordering sigmas in rice docstring.
parent 5a7680f0
 ... ... @@ -3884,6 +3884,23 @@ class Rice(PositiveContinuous): {\frac {x}{\sigma ^{2}}}\exp \left({\frac {-(x^{2}+\nu ^{2})}{2\sigma ^{2}}}\right)I_{0}\left({\frac {x\nu }{\sigma ^{2}}}\right), .. plot:: import matplotlib.pyplot as plt import numpy as np import scipy.stats as st plt.style.use('seaborn-darkgrid') x = np.linspace(0, 8, 500) nus = [0., 0., 4., 4.] sigmas = [1., 2., 1., 2.] for nu, sigma in zip(nus, sigmas): pdf = st.rice.pdf(x, nu / sigma, scale=sigma) plt.plot(x, pdf, label=r'$\nu$ = {}, $\sigma$ = {}'.format(nu, sigma)) plt.xlabel('x', fontsize=12) plt.ylabel('f(x)', fontsize=12) plt.legend(loc=1) plt.show() ======== ============================================================== Support :math:x \in (0, \infty) Mean :math:\sigma {\sqrt {\pi /2}}\,\,L_{{1/2}}(-\nu ^{2}/2\sigma ^{2}) ... ...
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!