Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates



generates random variates from over 870 univariate distributions

nfctrnbin_cdf(n, k, theta, nn)
% nfctrnbin_cdf.m - compute n-fold Convolution of Truncated Negative Binomial
%                   Cumulative Distribution Function.
%   See "Univariate Discrete Distributions", Johnson, Kemp, and Kotz,
%   J. Wiley, p.235, 2005.                 
%  Created by:  Jim Huntley,  07/26/07.

function [cdf] = nfctrnbin_cdf(n, k, theta, nn)

sum1 = 0;
for jn = nn:n
    sum1 = sum1 + nfctrnbin_pdf(jn, k, theta, nn);
cdf = sum1;


Contact us