Generate a set of pseudorandom numbers that are inverse gamma distributed:
Compare its histogram to the PDF:
Generate a set of pseudorandom numbers that have generalized inverse gamma distribution:
Compare its histogram to the PDF:
Distribution parameters estimation:
Estimate the distribution parameters from sample data:
Compare the density histogram of the sample with the PDF of the estimated distribution:
Skewness depends only on shape parameter

:
As

gets larger, the distribution becomes more symmetric:
The generalized case depends on both

and

:
Kurtosis depends only on shape parameter

:
The kurtosis approaches the kurtosis of
NormalDistribution
as

approaches

:
The generalized case depends on both

and

:
Different moments with closed forms as functions of parameters:
Different moments of generalized inverse gamma distribution:
Hazard function:
Hazard function of generalized inverse gamma distribution:
Quantile function:
Generalized inverse gamma distribution: