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

nbinbet_cdf(n, nn, w, r)
% nbinbet_cdf.m - evaluates a Negative Binomial Beta Cumulative Distribution.
%   See "A Compund of the Negative Binomial Distribution with the Generalized Beta Distribution"", A.K Gupta &,
%   T. Gerstenkorn, Central European Journal of Mathematics, 2(4) 2004, p.527. 
%  Created by Jim Huntley,  09/29/11

function [cdf] = nbinbet_cdf(n, nn, w, r)

sum1 = nbinbet_cdf(0, nn, w, r);
for jn = 1:n
    sum1 = sum1 + nbinbet_cdf(jn, nn, w, r);
cdf = sum1;


Contact us