Skip to content

Commit

Permalink
Add a check against negative support of degrees of freedom
Browse files Browse the repository at this point in the history
Co-authored-by: Ricardo <[email protected]>
  • Loading branch information
Sayam753 and ricardoV94 committed Jun 13, 2021
1 parent 694e4bc commit 5ab17d0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pymc3/distributions/multivariate.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

from pymc3.aesaraf import floatX, intX
from pymc3.distributions import transforms
from pymc3.distributions.continuous import ChiSquared, Normal
from pymc3.distributions.continuous import ChiSquared, Normal, assert_negative_support
from pymc3.distributions.dist_math import bound, factln, logpow
from pymc3.distributions.distribution import Continuous, Discrete
from pymc3.distributions.special import gammaln, multigammaln
Expand Down Expand Up @@ -342,6 +342,7 @@ def dist(cls, nu, Sigma=None, mu=None, cov=None, tau=None, chol=None, lower=True
nu = at.as_tensor_variable(floatX(nu))
mu = at.as_tensor_variable(floatX(mu))
cov = quaddist_matrix(cov, chol, tau, lower)
assert_negative_support(nu, "nu", "MvStudentT")
return super().dist([nu, mu, cov], **kwargs)

def logp(value, nu, mu, cov):
Expand Down

0 comments on commit 5ab17d0

Please sign in to comment.