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

genbeta2_cdf(x, a, b, gam)
% genbeta2_cdf.m - evaluatess a Generalized Beta II Cumulative Distribution.
%   See "A Generalized Beta Distribution II",  S. Nadarajah and S. Kotz 
%  Created by Jim Huntley,  02/09/10

function [cdf] = genbeta2_cdf(x, a, b, gam)

%persistent coef

    coef = b * beta(a,b) / ((a+b)*beta(a,b+gam));

cdf = coef .* x.^(a+b) .* pfq([1-gam,a],a+b+1,x);


Contact us