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

% logpears3_cdf.m - compute Log Pearson III Cumulative Distribution Function.
% "Estimating 7Q10 Confidence Limits from Data: A Bootstrap Approach", 
%   Daniel P. Ames, 
%                  Vector Form of CDF !!!
%  Created by:  Jim Huntley,  03/02/05.

function [cdf] = logpears3_cdf(x,lambda,bet,epsilon)

tol = 1e-8;
trace = [];
warning off MATLAB:quad:MinStepSize;

minx = min(x);

% Integrate PDF to get CDF.
sz = size(x,2);
for jz = 1:sz
    cdf(jz) = quad(@logpears3_pdf,minx,x(jz),tol,trace,lambda,bet,epsilon);


Contact us