Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates

by

 

generates random variates from over 870 univariate distributions

dbinom_cdf(n,nn,pii,psi)
% dbinom_cdf.m - compute a Double Binomial Cumulative Distribution Function.
%   See "Univariate Discrete Distributions", Johnson, Kemp, & Kotz,
%   J. Wiley, p.490, 2005.                 
%
%  Created by:  Jim Huntley,  12/15/06.
%

function [cdf] = dbinom_cdf(n,nn,pii,psi)

sum1 = dbinom_pdf(0,nn,pii,psi);
for jn = 1:n
    sum1 = sum1 + dbinom_pdf(jn,nn,pii,psi);
end
cdf = sum1;

return



Contact us