Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates


James Huntley (view profile)


generates random variates from over 870 univariate distributions

leftpois_cdf(n, theta, r1)
% leftpois_cdf.m - compute Left-Truncated Poisson Cumulative Distribution Function.
%   See "Univariate Discrete Distributions", Johnson, Kemp, and Kotz,
%   J. Wiley, p.190, 2005.                 
%  Created by:  Jim Huntley,  07/01/07.

function [cdf] = leftpois_cdf(n, theta, r1)

sum1 = 0;
for jn = r1:n
    sum1 = sum1 + leftpois_pdf(jn, theta, r1);
cdf = sum1;


Contact us