Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates

by

James Huntley (view profile)

 

generates random variates from over 870 univariate distributions

binhypmix_cdf(n, m, N1, Np, N2)
% binhypmix_cdf.m - compute Binomial Hypergeometric Mixture Cumulative Distribution Function.
%   See "Univariate Discrete Distributions", Johnson, Kemp, and Kotz,
%   J. Wiley, p.375, 2005.                  
%
%  Created by:  Jim Huntley,  11/21/06.
%

function [cdf] = binhypmix_cdf(n, m, N1, Np, N2)

sum1 = binhypmix_pdf(0, m, N1, Np, N2);

for jn = 1:n
    sum1 = sum1 + binhypmix_pdf(jn, m, N1, Np, N2);
end

cdf = sum1;

return



Contact us