On 7/26/2013 8:03 AM, Robert wrote:
> I frequently use glmfit for fitting probit regression models, in much
> the same way as shown in the help section for the glmfit function:
>
> % Example: Fit a probit regression model for y on x. Each y(i) is the
> % number of successes in n(i) trials.
> x = [2100 2300 2500 2700 2900 3100 3300 3500 3700 3900 4100
> 4300]';
> n = [48 42 31 34 31 21 23 23 21 16 17 21]';
> y = [1 2 0 3 8 8 14 17 19 15 17 21]';
> b = glmfit(x, [y n], 'binomial', 'link', 'probit');
> yfit = glmval(b, x, 'probit', 'size', n);
> plot(x, y./n, 'o', x, yfit./n, '')
>
> However, I would also like to know how to derive the estimated value
> of x associated with a given threshold 'success' probability (and
> associated confidence limits if possible). For example, this threshold
> value is commonly the 50% point, where half of responses are
> 'successes' and half are not.
>
> Any advice would be much appreciated!
>
> Many thanks,
> Robert
I don't know how to calculate confidence limits, but you can calculate
the 50% point pretty easily:
r = @(x)glmval(b,x,'probit').5;
ranswer = fzero(r,[2500,3500])
ranswer =
3.1958e+03
Alan Weiss
MATLAB mathematical toolbox documentation
