[R] linear functional relationships with heteroscedastic & non-Gaussian errors - any packages around?

Prof Brian Ripley ripley at stats.ox.ac.uk
Tue Dec 2 18:34:30 CET 2008


I wonder if you are using this term in its correct technical sense.
A linear functional relationship is

V = a + bU
X = U + e
Y = V + f

e and f are random errors (often but not necessarily independent) with 
distributions possibly depending on U and V respectively.

and pairs from (X,Y) are observed.  As U and V are not random, there is 
no PDF of X or Y: each X_i has a different distribution.  If you know 
the error distribution for each X_i and Y_i, you can easily write down a 
log-likelihood and maximize it.

The first hit I got on Google, 
http://www.rsc.org/Membership/Networking/InterestGroups/Analytical/AMC/Software/FREML.asp, 

has a reference to a paper for the Gaussian case.

But finding R code for the non-Gaussian case seems a very long shot.

Jarle Brinchmann wrote:
> [apologies if this appears twice]

It did ...

> 
> Hi,
> 
> I have a situation where I have a set of pairs of X & Y variables for
> each of which I have a (fairly) well-defined PDF. The PDF(x_i) 's and
> PDF(y_i)'s  are unfortunately often rather non-Gaussian although most
> of the time not multi-modal.
> 
> For these data (estimates of gas content in galaxies), I need to
> quantify a linear functional relationship and I am trying to do this
> as carefully as I can. At the moment I am carrying out a Monte Carlo
> estimation, sampling from each PDF(x_i) and PDF(y_i) and using a
> orthogonal linear fit for each realisation but that is not very
> satisfactory as it leads to different linear relationships depending
> on whether I do the orhtogonal fit on x or y (as the errors on X & Y
> are quite different & non-Gaussian using the covariance matrix isn't
> all that useful
> either)
> 
> Does anybody know of code in R to do this kind of fitting in a
> Bayesian framework? My concern isn't so much on getting _the_ best
> slope estimate but rather to have a good estimate of the uncertainty
> on the slope.
> 
>       Cheers,
>             Jarle.


-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595



More information about the R-help mailing list