Continuous uniform parameter estimates
[ahat,bhat] = unifit(data)
[ahat,bhat,ACI,BCI] = unifit(data)
[ahat,bhat,ACI,BCI] = unifit(data,alpha)
[ahat,bhat] = unifit(data)
returns the maximum likelihood estimates (MLEs) of the parameters of the uniform distribution given the data indata
.
[ahat,bhat,ACI,BCI] = unifit(data)
also returns 95% confidence intervals,ACI
andBCI
, which are matrices with two rows. The first row contains the lower bound of the interval for each column of the matrixdata
. The second row contains the upper bound of the interval.
[ahat,bhat,ACI,BCI] = unifit(data,alpha)
controls the confidence level by usingalpha
. For example, ifalpha
=0.01
, thenACI
andBCI
are 99% confidence intervals.
r = unifrnd(10,12,100,2); [ahat,bhat,aci,bci] = unifit(r) ahat = 10.0154 10.0060 bhat = 11.9989 11.9743 aci = 9.9551 9.9461 10.0154 10.0060 bci = 11.9989 11.9743 12.0592 12.0341