betalike
              Negative log-likelihood for the Beta distribution.
 nlogL = betalike (params, x) returns the negative
 log likelihood of the data in x corresponding to the Beta distribution
 with (1) shape parameter  and (2) shape parameter  given in
 the two-element vector params.  Both parameters must be positive real
 numbers and the data in the range .  Out of range parameters or
 data return NaN.
 [nlogL, avar] = betalike (params, x) returns
 the inverse of Fisher’s information matrix, avar.  If the input
 parameter values in params are the maximum likelihood estimates, the
 diagonal elements of params are their asymptotic variances.
 The Beta distribution is defined on the open interval .  However,
 betafit can also compute the unbounded beta likelihood function for
 data that include exact zeros or ones.  In such cases, zeros and ones are
 treated as if they were values that have been left-censored at
 sqrt (realmin) or right-censored at 1 - eps/2, respectively.
Further information about the Beta distribution can be found at https://en.wikipedia.org/wiki/Beta_distribution
See also: betacdf, betainv, betapdf, betarnd, betafit, betastat
Source Code: betalike