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

% genwar_cdf.m - compute a Generalized Waring Cumulative Distribution Function.
% "Recursions for Compound Distributions",
%     H. Panjer & G. Wilmot, ASTIN Bull, Vol. 13, No. 1, p. 1.               
%  Created by:  Jim Huntley,  02/26/07.

function [cdf] = genwar_cdf(n,a,b,alpha)

sum = genwar_pdf(0, a, b, alpha);
for jn = 1:n
    sum = sum + genwar_pdf(jn, a, b, alpha);
cdf = sum;


Contact us