[R] 'asymmetric span' for 2D loess?
Prof Brian Ripley
ripley at stats.ox.ac.uk
Tue Jun 3 08:20:08 CEST 2008
On Mon, 2 Jun 2008, Tokuyasu, Taku wrote:
> Hello,
>
> I am interested in performing a 2D loess smooth on microarray data, i.e.
> log2 ratios on a 2D grid, using different spans in the horizontal and
> vertical directions (the immediate reason being that replicate spots are
> laid out in the horizontal direction). Is it possible to do this in R?
> Functions like loess(stats) seem to apply the same span for all
> predictors, which carries over to functions like ma2D(marray).
See the next comment. 'span' applies to 2D distances, and I think you
need to rescale your inputs so Euclidean distance is appropriate.
> As an elementary second question, are there circumstances where one
> expects to see a substantial difference in the fits between say loess(y
> ~ x1 + x2) and loess(y ~ x1 * x2) with an interaction term (and if so,
> what are they)?
>From the help page:
formula: a formula specifying the numeric response and one to four
numeric predictors (best specified via an interaction, but
can also be specified additively). Will be coerced to a
formula if necessary.
So the two versions both specify smoothing in 2D.
You can use things like lo(x1) + lo(x2) in some gam fits.
It often helps to read the primary sources, in this case chapters in the
White Book (Chambers & Hastie, nominally 1992, actually published in
1991).
>
> Many thanks,
>
> _Taku
>
> Taku A. Tokuyasu, PhD
> UCSF Helen Diller Family Comprehensive Cancer Center
> San Francisco, CA 94143-0808
--
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