Home > . > qchisq.m

qchisq

PURPOSE ^

QCHISQ The chisquare inverse distribution function

SYNOPSIS ^

function x = qchisq(p,a)

DESCRIPTION ^

QCHISQ   The chisquare inverse distribution function

         x = qchisq(p,DegreesOfFreedom)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function x = qchisq(p,a)
0002 %QCHISQ   The chisquare inverse distribution function
0003 %
0004 %         x = qchisq(p,DegreesOfFreedom)
0005 
0006 %        Anders Holtsberg, 18-11-93
0007 %        Copyright (c) Anders Holtsberg
0008 
0009 if any(any(abs(2*p-1)>1))
0010    error('A probability should be 0<=p<=1, please!')
0011 end
0012 if any(any(a<=0))
0013    error('DegreesOfFreedom is wrong')
0014 end
0015 
0016 x = qgamma(p,a*0.5)*2;

Generated on Fri 16-Jun-2006 09:09:06 by m2html © 2003