借助sympy.stats.JointRV()
方法,我們可以獲得代表馮·米塞斯分布的連續聯合隨機變量。
用法:sympy.stats.JointRV(name, pdf)
返回:Return the continuous joint random variable.
範例1:
在這個例子中,我們可以通過使用sympy.stats.JointRV()
通過這種方法,我們可以獲得代表JointRV分布的連續關節隨機變量。
# Import sympy and JointRV
from sympy.stats import JointRV, density
from sympy import Symbol, pprint
z = Symbol("z")
pdf = 2 * pi * z
# Using sympy.stats.JointRV() method
X = JointRV("x", pdf)
gfg = density(X)
pprint(gfg)
輸出:
JointDistributionHandmade(Lambda((), 2*pi*z), FiniteSet(()))
範例2:
# Import sympy and JointRV
from sympy.stats import JointRV, density
from sympy import Symbol, pprint
z = 3
pdf = 2 * pi * z
# Using sympy.stats.JointRV() method
X = JointRV("x", pdf)
gfg = density(X)
pprint(gfg)
輸出:
6*pi
相關用法
- Python sympy.sin()用法及代碼示例
- Python sympy.nT()用法及代碼示例
- Python sympy.Add()用法及代碼示例
- Python sympy RGS用法及代碼示例
- Python sympy.ff()用法及代碼示例
- Python sympy.tan()用法及代碼示例
- Python sympy.apart()用法及代碼示例
- Python sympy.nC()用法及代碼示例
- Python sympy.nP()用法及代碼示例
- Python sympy.Mul()用法及代碼示例
- Python sympy.S()用法及代碼示例
- Python sympy.rf()用法及代碼示例
- Python sympy.eye()用法及代碼示例
- Python sympy.csc()用法及代碼示例
- Python sympy.Pow()用法及代碼示例
- Python sympy.gcd()用法及代碼示例
- Python sympy.cot()用法及代碼示例
- Python sympy.sec()用法及代碼示例
- Python sympy.cos()用法及代碼示例
- Python sympy.ones()用法及代碼示例
注:本文由純淨天空篩選整理自Jitender_1998大神的英文原創作品 Sympy stats.JointRV() in Python。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。