Exponential PDF
y = distfun_exppdf ( x , mu )
a matrix of doubles
a matrix of doubles, the average. Must be positive.
a matrix of doubles, the density
This function computes the Exponential PDF.
Any scalar input argument is expanded to a matrix of doubles of the same size as the other input arguments.
Any optional input argument equal to the empty matrix will be set to its default value.
The exponential distribution with average mu has density
for x >= 0.
Notice that mu, the average, is the inverse of the rate. Other computing languages (including R), use 1/mu as the parameter of the exponential distribution.
// http://en.wikipedia.org/wiki/Exponential_distribution scf(); x = linspace(0,5,1000); y = distfun_exppdf ( x , 2 ); plot(x,y, "r-" ); y = distfun_exppdf ( x , 1 ); plot(x,y, "m-" ); y = distfun_exppdf ( x , 2/3 ); plot(x,y, "c-" ); xtitle("Exponential PDF","x","f(x)"); legend(["mu=2","mu=1","mu=2/3"]); | ![]() | ![]() |
Wikipedia, Exponential distribution function, http://en.wikipedia.org/wiki/Exponential_distribution