forked from JuliaStats/Distributions.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
A multivariate lognormal using MvNormal internally.
Implements the same constructors as MvNormal, as well as the interface discussed in the Distributions documentation. No changes to the existing code from Distributions. The tests are very similar to the ones for MvNormal itself. Also contains functionality to calculate the scale and location for a lognormal given some desired statistics for the distribution. This functionality is needed in e.g., MCMC methods, where you need to center a distribution around e.g. the median or mode. In particular, there are functions that allow to calculate: (1) location and scale for a given mean and covariance (2) location for a given scale and either mean, median or mode (location and scale cannot be calculated analytically from e.g., mode and covariance) The added scale and location functions are the equivalent of static class functions in C++ (typed on ::Type{MvLogNormal}) to ensure correct dispatch. I added tests to test/mvlognormal.jl for all functionality Added documentation for the multivariate lognormal distribution. Fixing indentation and removed AbstractMvLogNormal from exported types.
- Loading branch information
Showing
6 changed files
with
379 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.