| MATLAB Function Reference | ![]() |
I = betainc(X,Z,W)
I = betainc(X,Z,tail)
The incomplete beta function is
![]()
where
, the beta function,
is defined as
![]()
and
is the gamma function.
I = betainc(X,Z,W) computes the
incomplete beta function for corresponding elements of the arrays X, Z,
and W. The elements of X must be in
the closed interval
. The arrays Z and W must
be nonnegative and real. All arrays must be the same size, or any of them
can be scalar.
I = betainc(X,Z,tail) specifies the tail of the incomplete beta function. Choices are:
'lower' (the default) | Computes the integral from 0 to x |
'upper' | Computes the integral from x to 1 |
These functions are related as follows:
1-betainc(X,Z,W) = betainc(X,Z,W,'upper')
Note that especially when the upper tail value is close to 0, it is more accurate to use the 'upper' option than to subtract the 'lower' value from 1.
format long betainc(.5,(0:10)',3) ans = 1.00000000000000 0.87500000000000 0.68750000000000 0.50000000000000 0.34375000000000 0.22656250000000 0.14453125000000 0.08984375000000 0.05468750000000 0.03271484375000 0.01928710937500
![]() | beta | betaln | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |