I noticed that calculating the standard deviation of a LogNormal distribution directly or from a very large sample yields quite different results. This is not true for the mean.
Based on my inspection, the implementation the Log Normal distribution appears to be correct. I believe Dan is correct about the heavy tails introducing uncertainty into the estimates of the mean and standard deviation. One example of a heavy-tailed distribution without a defined variance is the Cauchy distribution.
The sample variance (and standard deviation) is a statistic and as such it has a convergence rate. In tame distributions, this rate depends on the 4th moment.
Doing the relevant searches for the exact expressions, I found the following:
# variance of sample variance
# m4 = 4th moment
# s4 = standard deviation ^ 4
# n = number of samples
vars2(m4,s4,n) = m4/n - s4*(n-3)/n/(n-1)
# LogNormal 4th moment given mu and sd
lognormal_m4(mulog, sdlog) = exp(4*mulog + (1/2)*16*sdlog^2)
# LogNormal standard deviation ^ 4 given mu and sd
lognormal_s4(mulog, sdlog) = var(Distributions.LogNormal(mulog, sdlog))^2
# Calculation relevant to post
vars2(lognormal_m4(-12.0, 3.0), lognormal_s4(-12.0, 3.0),1000000) # = 26489.122129843465
The result 26489.1(β¦) is clearly too large to get an accurate sample standard deviation.
For mu=1.0 sd=1.0, it gives 0.16 with same n, enough to get accuracy for the population sd of 5.87(β¦).
This was a bit of a hasty calculation/google, but the results make sense.