dist function suggestion
Prof Brian Ripley
Prof Brian Ripley <ripley@stats.ox.ac.uk>
Wed, 20 Jan 1999 13:09:47 +0000 (GMT)
> Date: Wed, 20 Jan 1999 12:03:38 +0000 (GMT)
> From: Jonathan Rougier <J.C.Rougier@durham.ac.uk>
> To: Friedrich Leisch <Friedrich.Leisch@ci.tuwien.ac.at>
> cc: r-devel@stat.math.ethz.ch
> Subject: Re: dist function suggestion
>
> On Wed, 20 Jan 1999, Friedrich Leisch wrote:
>
> > dist is contained in the mva package which comes with (base) R. it
> > provides `"euclidian"', `"maximum"', `"manhattan"', `"canberra"' and
> > `"binary"' distances both in matrix and triangular form.
>
> Thanks Fritz, but could I still make a general plea for a dist() that
> takes one OR two matrices? I often need to find dist(X, Y) as a
> rectangular matrix (eg covariance calculations), and it is very
> inefficient to use dist(rbind(X, Y)) and then discard most of it.
You will need to call it something else: dist is a clone of an S function,
and dist(X, "manhattan") is well-established usage.
I pointed out to R-core recently that "euclidian" will cause problems
for those who know how to spell it .... (-ean in my dictionaries, and
in S).
--
Brian D. Ripley, ripley@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 272860 (secr)
Oxford OX1 3TG, UK Fax: +44 1865 272595
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._