Generating lognormal distribution

imohamed

New Member
Joined
Jan 6, 2009
Messages
2
Hi,
I need to generate lognormal distribution of a product price. Assuming the mean of the price is 40 and the std dev is 25, how do I use the built in function in excel eg, loginv and lognormdist to generate the lognormal distribution.

Thanks.
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
Hello and Welcom to the board.
do you need density function or cumulative function?
 
Upvote 0
Assuming that B1= 40 (mean) and B2 = 25 (standard deviation)

Code:
A5 = 0.001
A6 = A5 + $A$5 
and drag this formula down to A1003
B5 = =LOGINV(A5,LN($B$1)-0.5*(LN(($B$2/$B$1)^2+1)),SQRT(LN(($B$2/$B$1)^2+1)))
and drag this formula down to B1003
C5 = =EXP(-((LN(B5)-(LN($B$1)-0.5*LN(($B$2/$B$1)^2+1)))^2)/(2*LN(($B$2/$B$1)^2+1)))/B5/SQRT(LN(($B$2/$B$1)^2+1))/SQRT(2*PI())
and drag this formula down to C1003

Plot column B and C for probability density function
Plot column B and A for cumulative function
 
Upvote 0
Note that Column A is supposed to be the uniform random number generator. I have used fixed values of random number with a step value of 0.001 so that you can plot the values easily.
 
Upvote 0

Forum statistics

Threads
1,217,364
Messages
6,136,117
Members
449,993
Latest member
Sphere2215

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top