Noncentral T CDF
p = distfun_nctcdf ( x , v , delta ) p = distfun_nctcdf ( x , v , delta , lowertail )
a matrix of doubles, the outcome.
a matrix of doubles, the number of degrees of freedom, v>0.
a matrix of doubles, the noncentrality parameter, delta is real
a 1-by-1 matrix of booleans, the tail (default lowertail=%t). If lowertail is true (the default), then considers P(X<=x) otherwise P(X>x).
a matrix of doubles, the probability.
Computes the Noncentral T cumulated distribution function.
Any scalar input argument is expanded to a matrix of doubles of the same size as the other input arguments.
Caution This distribution is known to have inferior accuracy in some cases.
p = distfun_nctcdf(8,2,10) expected=0.2164194 // Plot the function h=scf(); x = linspace(-5,10,1000); p1 = distfun_nctcdf(x,1,0); p2 = distfun_nctcdf(x,4,0); p3 = distfun_nctcdf(x,1,2); p4 = distfun_nctcdf(x,4,2); plot(x,p1,"r") plot(x,p2,"g") plot(x,p3,"b") plot(x,p4,"k") legend(["v=1, delta=0", .. "v=4, delta=0", .. "v=1, delta=2", .. "v=4, delta=2"]); xtitle("Noncentral T CDF","x","$P(X\leq x)$"); | ![]() | ![]() |