Find function for log-normal distribution

95 Views Asked by At

I have a set of log-normal distributed values below.

I want to find the log-normal curve, which describes the shape of the distribution. I took the default log-normal formular and tried some values (see at Function Plotter):

1 / sqrt(2*pi*x*0.012) * exp(-(ln(x)-2.7)^2/(2*0.6^2))

But how can I find the exact parameters for my formular, so that the curve fits to the distribution? Can I do this using Mean/SD/Skewness/Kurtosis?

Mean: 23.8
Standard deviation: 21.9
Skewness: 2.28
Kurtosis: 12.3

Left image is my distribution, right image is the distribution and the curve together:

Log normal

2

There are 2 best solutions below

0
On

Given that you have a finite sample size from a distribution/DGP, it usually is impossible to find the exact parameters that describe the DGP. In fact, there is a whole field of mathematics which studies ways to determine approximations to the true parameters, namely statistics.

A popular estimator for parameters (but definitely not the only option) is called the maximum likelihood estimator. A very brief derivation for the lognormal distribution can be found on wikipedia. The result is \begin{align} \hat\mu_{ML} = \frac{\sum_{k=1}^{n} \log x_k}{n} && \hat\sigma^{2}_{ML}= \frac{\sum_{k=1}^{n} (\log x_k-\hat\mu_{ML})^2}{n} \end{align}

0
On

The mean and variance of the distribution are

$$m=e^{\mu+\sigma^2/2},v=(e^{\sigma^2}-1)e^{2\mu+\sigma^2}.$$

Hence,

$$\sigma^2=\ln\left(\frac v{m^2}+1\right),\mu=\ln(m)-\frac{\sigma^2}2.$$

These are not perfect estimators, but a good start.