Tuesday, November 26, 2024
Google search engine
HomeLanguagessympy.stats.YuleSimon() in Python

sympy.stats.YuleSimon() in Python

With the help of sympy.stats.YuleSimon() method, we can get the random variable representing the Yule-Simon distribution.

Syntax : sympy.stats.YuleSimon(name, rho)
Return : Return the random variable.

Example #1 :
In this example we can see that by using sympy.stats.YuleSimon() method, we are able to get the Yule-Simon distribution by using this method.




# Import sympy and Yule-Simon
from sympy.stats import YuleSimon, density, E, variance
from sympy import Symbol, simplify
  
rho = 5
  
# Using sympy.stats.YuleSimon() method
X = YuleSimon("X", rho)
gfg = density(X)(0.5)
  
print(gfg)


Output :

5*beta(0.5, 6)

Example #2 :




# Import sympy and Yule-Simon
from sympy.stats import YuleSimon, density, E, variance
from sympy import Symbol, simplify
  
rho = 5
z = Symbol("z")
  
# Using sympy.stats.YuleSimon() method
X = YuleSimon("X", rho)
gfg = density(X)(z)
  
print(gfg)


Output :

5*beta(z, 6)

Dominic Rubhabha-Wardslaus
Dominic Rubhabha-Wardslaushttp://wardslaus.com
infosec,malicious & dos attacks generator, boot rom exploit philanthropist , wild hacker , game developer,
RELATED ARTICLES

Most Popular

Recent Comments