# log-normal distribution of raw data vs. normal distribution of log data

I often assume that my data follow the normal distribution (concentrations of various pollutants in biota). The definition says that the data follow the log-normal distribution when normally distributed after logging. I see that when I plot my log data.

However, when I wanted to verify my choice of the distribution with the fitdistrplus package in R, I noticed some things I did not understand. The question is why when I chose "lnorm" distribution (fitdist(x, "lnorm"), the data poorly lie on a QQ-line, but when I chose norm for log x, the data fit the line very well (fitdist(log(x), "norm"). I thought that fitdist(x, "lnorm") should give the same results as fitdist(log(x), "norm").

In my simulation it gives the same estimates for the fitdist(log(x), "norm") and fitdist(x, "lnorm") and the histograms look ok. probably a typo in your code. or check how it handles missing data, maybe there is smth there

#code
#simulate lognormal sample
xxx = exp(rnorm(100, 0,1))
fitdist(xxx, "lnorm")
fitdist(log(xxx), "norm")

hist(log(xxx), probability = TRUE)
grid = seq(min(log(xxx)), max(log(xxx)), length.out = 100)
lines (x = grid, y =  dnorm(grid, mean(log(xxx)), sd(log(xxx)) ),
col = 2)

hist(xxx, probability = TRUE)
grid = seq(min(xxx), max(xxx), length.out = 100)
lines (x = grid, y =  dlnorm(grid, mean(xxx), sd(xxx) ), col = 2)

#results
## xxx = exp(rnorm(100, 0,1))
##> fitdist(xxx, "lnorm")
## Fitting of the distribution ' lnorm ' by maximum likelihood
## Parameters:
##       estimate Std. Error
## meanlog  0.04965     0.1028
## sdlog    1.02820     0.0727
##> fitdist(log(xxx), "norm")
## Fitting of the distribution ' norm ' by maximum likelihood
## Parameters:
##     estimate Std. Error
## mean  0.04965     0.1028
## sd    1.02820     0.0727


• Thank you for the reply. I run it again on my data - indeed, the parameters are the same, but still the figures look different. I thought that QQ-plot should look completely the same. Am I wrong? I uploaded both figures to 1drv.ms/u/s!AuRBSy2nUdUViahJEmwaUQi9p81Inw?e=brVewN
– ljb
Dec 8, 2021 at 11:24
• They look similar to me in the fit, the QQ have quantiles in the X-axis, so the same quantiles will spread differently in log- and non-logged space, so they can not be identical Dec 8, 2021 at 13:48
• Thank You! Now I understand the issue.
– ljb
Jan 6, 2022 at 10:11