日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程语言 > python >内容正文

python

bernoulli_Python-Bernoulli发行

發布時間:2023/12/14 python 26 豆豆
生活随笔 收集整理的這篇文章主要介紹了 bernoulli_Python-Bernoulli发行 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

bernoulli

Python-Bernoulli發行 (Python - Bernoulli Distribution)

The Bernoulli distribution is a special case of the Binomial distribution where a single experiment is conducted so that the number of observation is 1. So, the Bernoulli distribution therefore describes events having exactly two outcomes.

伯努利分布是二項分布的一種特例,在該二項分布中進行了一次實驗,因此觀察次數為1。因此,伯努利分布描述的事件恰好具有兩個結果。

We use various functions in numpy library to mathematically calculate the values for a bernoulli distribution. Histograms are created over which we plot the probability distribution curve.

我們在numpy庫中使用各種函數來數學計算bernoulli分布的值。 將創建直方圖,在該直方圖上繪制概率分布曲線。

from scipy.stats import bernoulli import seaborn as sbdata_bern = bernoulli.rvs(size=1000,p=0.6) ax = sb.distplot(data_bern,kde=True,color='crimson',hist_kws={"linewidth": 25,'alpha':1}) ax.set(xlabel='Bernouli', ylabel='Frequency')

Its output is as follows ?

其輸出如下-

翻譯自: https://www.tutorialspoint.com/python_data_science/python_bernoulli_distribution.htm

bernoulli

總結

以上是生活随笔為你收集整理的bernoulli_Python-Bernoulli发行的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。