Path: news.mathworks.com!not-for-mail
From: "Tom Lane" <tlane@mathworks.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Fitting CDF of Beta distribution data
Date: Wed, 21 May 2008 21:15:31 -0400
Organization: The MathWorks, Inc.
Lines: 40
Message-ID: <g12hfj$80e$1@fred.mathworks.com>
References: <g0v407$9e9$1@fred.mathworks.com>
Reply-To: "Tom Lane" <tlane@mathworks.com>
NNTP-Posting-Host: lanet.dhcp.mathworks.com
X-Trace: fred.mathworks.com 1211418931 8206 172.31.57.120 (22 May 2008 01:15:31 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 22 May 2008 01:15:31 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
Xref: news.mathworks.com comp.soft-sys.matlab:469783



Pete, with the "probit" link function you are saying the binomial 
probabilities follow the form of a normal cdf.  The b(1) and b(2) parameters 
adjust the mean and standard deviation of the distribution function.

That's not the case with a beta distribution.  It's not a location/scale 
family.  It would be possible to use a beta distribution function with 
parameters that you specify in advance, and then let the b(1) and b(2) 
parameters define a location/scale transformation of that.  I'll bet that's 
not what you intend, though.  Also, unlike the normal, this distribution has 
zero probability outside a finite range; this may or may not cause troubles 
for you..

I can't think of any way to use glmfit and estimate the beta function 
parameters.  I have seen work people have done to estimate parameters in a 
link function.  If that's what you really want, let me know.  Maybe I can 
find a reference.

-- Tom

"Pete sherer" <tsh@abg.com> wrote in message 
news:g0v407$9e9$1@fred.mathworks.com...
> Right now I am fitting the CDF data using the normal
> distribution via the GLMFIT. Are there any way I can do the
> same fitting but assuming the BETA distribution.
>
> The current code I am using to fit Normal CDF data is as
> shown below:
> x = [0.1294;0.2211;0.3779;0.5559;0.7034;0.8901;1.1263;];
> y = [0;0;0.004;0.007;0.029;0.078;0.192;];
>
> Y    = roundn( [y*100  100*ones(length(y), 1)], 0);
> b    = glmfit( x, Y, 'binomial', 'link', 'probit');
>
> % Equivalent Normal parameters are (From Tom Lane):
> mean   = -b(1)/b(2);
> stdDev = 1/b(2);
>
> Thank you very much for your help,