mitchelloharawild / distributional

Vectorised distributions for R
https://pkg.mitchelloharawild.com/distributional
GNU General Public License v3.0
97 stars 15 forks source link

dist_multivariate_normal() error for default arguments #118

Open robjhyndman opened 2 months ago

robjhyndman commented 2 months ago
library(distributional)
dist_multivariate_normal() |> density(0)
#> Error in if (p != ncol(sigma)) stop("x and sigma have non-conforming size"): argument is of length zero
dist_multivariate_normal(list(0), sigma = list(diag(1))) |> density(0)
#> [1] 0.3989423

Created on 2024-07-31 with reprex v2.1.1