Re: random numbers from a lognormal distribution

From: Bob Wheeler (bwheeler_at_echip.com)
Date: 02/02/05


Date: Wed, 02 Feb 2005 09:39:02 -0500

Dave wrote:
> On Tue, 01 Feb 2005 20:33:15 -0600, Ray Koopman wrote:
>
>>Bob Wheeler wrote:
>>
>>>[...]
>>>I think he is asking how to do it himself. If X is a standard
>
> normal variate, then U=(log(X)-m)/s is lognormal with mean
> exp(m)sqrt(w), where w=exp(s^2), and variance exp(2m)w(w-1).
>
>>Shouldn't that be "If X is a standard normal variate then
>
> U=exp(X*s+m) is lognormal ..."?
>
>
> This confusion reminds me of a trick I figured out for working with
> the lognormal distribution...
>
> I always had trouble working with the formulas for converting the mean
> and standard deviation from the normal distribution to the lognormal
> distribution, and vice versa, E(x)-->E(lnx), V(x)-->V(lnx) and so
> forth. One day it occurred to me that both distributions are
> completely characterized by 2 pieces of information, and that the mean
> and standard deviation aren't the only 2 pieces of information I could
> use. They're the traditional pieces of information, but they're not
> the only ones.
>
> I discovered that the median and interquartile range are much easier
> to use, so that's what I use now.
>
> The transformation functions exp(x) and ln(x) are non-decreasing
> functions, and for any non-decreasing function g(x), the percentiles
> of x and g(x) are easy to derive from each other. If x_p is the p-th
> percentile of the random variable x, then g(x_p) is the p-th
> percentile of the random variable g(x).
>
> In particular, if m is the median of a normal distribution, then ln(m)
> is the median of the corresponding lognormal distribution. And if m
> is the median of a lognormal distribution, then exp(m) is the median
> of the corresponding normal distribution. The same goes for the 25-th
> and 75-th percentiles, and that allows me to calculate the
> interquartile ranges of both distributions fairly easily.
>
> So now whenever I work with the lognormal distribution, I use the
> median and interquartile range as my 2 pieces of information instead
> of the mean and standard deviation. Try it. I like it much better.
>

Right, thanks Ray. I copied in haste from my notes.

Dave you might like to take a look at my Johnson curve paper for more
details about the quantile stuff: Wheeler, R.E. (1980). Quantile
estimators of Johnson curve parameters. Biometrika. 67-3 725-728

There's a copy on my stat website.

-- 
Bob Wheeler --- http://www.bobwheeler.com/
         ECHIP, Inc. ---
Randomness comes in bunches.


Relevant Pages

  • Re: computing on streams of data
    ... you need to be able to keep a running median for the first N values? ... We wanted to be able to show the distribution of values ... What I ended up doing was creating bins that were logarithmically ... a K-bit approximation using significantly fewer bits than for the ...
    (comp.theory)
  • Re: Age of Earth according to some Americans
    ... The median by definition must fall right in ... the symmetry of the distribution. ... science and critical thinking. ... For historic reasons the Fundie minority seems louder ...
    (talk.origins)
  • Re: Median likelihood?
    ... of the likelihood function or the median of the log likelihood ... Median is of a probability distribution (such as the sampling ... distribution is equal to the parameter being estimated, an estimator ...
    (sci.stat.math)
  • Re: Median likelihood?
    ... of the likelihood function or the median of the log likelihood ... Median is of a probability distribution (such as the sampling ... distribution is equal to the parameter being estimated, an estimator ...
    (sci.stat.math)
  • Re: How to simulate Cauchy samples
    ... Putting F = RND we are able to GENERATE samples of whichever size n having the Cauchy Density... ... In order to find FRACTILES of the median: ... intervals of the Cauchy distribution is an interesting problem, ... population median, so you estimate that the population median is 1. ...
    (sci.stat.math)