StatsPlots.jl icon indicating copy to clipboard operation
StatsPlots.jl copied to clipboard

Feature request MvNormal for covellipse

Open ga72kud opened this issue 3 years ago • 3 comments

It would be nice if the second line would also work

N=MvNormal(μ, Σ)

covellipse(N, n_std=2, aspect_ratio=1, label="cov1")

covellipse(μ, Σ, n_std=2, aspect_ratio=1, label="cov1")

ga72kud avatar Feb 10 '22 09:02 ga72kud

I agree, this would be nice.

In general I think this code can be improved. e.g. We can support trivariate normals by plotting an ellipsoid. We can also support n-variate normals by allowing the user to specify which slice of the covariance matrix should be plotted. A corellipse function would be useful as well. And we could even go so far as to support something like corrplot that plots ellipses for all bivariate slices of the covariance matrix.

Then, for Bayesian modeling, it's useful to view distributions of covariance/correlation matrices. This paper introduces some plots for this: http://www.stat.columbia.edu/~gelman/research/unpublished/Visualization.pdf

sethaxen avatar Feb 10 '22 10:02 sethaxen

Thank you! That sounds great!

ga72kud avatar Feb 10 '22 11:02 ga72kud

@ga72kud I'm re-opening so we can track this feature.

sethaxen avatar Feb 14 '22 09:02 sethaxen