Skip to content

Commit

Permalink
Merge branch 'port-distribution' of github.com:farhanreynaldo/pymc3 i…
Browse files Browse the repository at this point in the history
…nto port-distribution
  • Loading branch information
farhanreynaldo committed May 14, 2021
2 parents 3773ce4 + 6231293 commit e0c6b97
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions pymc3/distributions/continuous.py
Original file line number Diff line number Diff line change
Expand Up @@ -1470,6 +1470,21 @@ def logcdf(value, mu):
)


class LaplaceRV(RandomVariable):
name = "laplace"
ndim_supp = 0
ndims_params = [0, 0]
dtype = "floatX"
_print_name = ("Laplace", "\\operatorname{Laplace}")

@classmethod
def rng_fn(cls, rng, mu, b, size=None):
return stats.laplace.rvs(mu, b, size=size, random_state=rng)


laplace = LaplaceRV()


class Laplace(Continuous):
r"""
Laplace log-likelihood.
Expand Down

0 comments on commit e0c6b97

Please sign in to comment.