This widget could not be displayed.
Created:
Feb 11, 2009 01:18 PM
| Last Modified:
Feb 11, 2009 10:18 AM
(4001 views)
| Posted in reply to message from 02-10-2009
Fred,
The arguments are Normal Density(x, mu, sigma). For example, the code
Normal Density(98, 100, 10)
returns the value 0.039104269.
Just for fun, the code below draws a normal curve with sliders for the mean and sigma. You can modify the code to fit your purposes.
mu = 0;
sigma = 1;
New Window( "Normal Curve",
gdey = Graph Box(
Y Scale( -.05, .5 ),
X Scale( -10, 10 ),
XName( "y" ),
Pen Color( "red" );
Y Function( normal density(y, mu, sigma), y );
),
H List Box( Slider Box( -5, 5, mu, gdey << reshow ), Text Box( "mu" ) ),
H List Box( Slider Box( 0, 5, sigma, gdey << reshow ), Text Box( "sigma" ) )
);