pangolin.interface.Interface.multi_normal

pangolin.interface.Interface.multi_normal#

Interface.multi_normal(mean, cov)[source]#

Create a multivariate normal RV.

The mean must have shape (n,) and the covariance must have shape (n, n). The result has shape (n,). Positive-definiteness of the covariance is value-dependent and therefore remains a backend-level constraint.

Parameters:
  • mean (RVLike) – Mean vector.

  • cov (RVLike) – Covariance matrix.

Return type:

RV

Examples

>>> import pangolin.interface as pi
>>> pi.multi_normal([0, 0], [[1, 0], [0, 1]]).shape
(2,)