Skip to content
Prev 5520 / 398506 Next

alas, no vecnorm

On Thu, 4 May 2000, Faheem Mitha wrote:

            
Funny, it is on page 55 of the _second_ edition, and not in the third.
It is the third edition that is R-aware.  Have you really just bought a
second edition?
Well, it was not overlooked.  R is not an S-PLUS clone, it is similar to S,
and AFAIK vecnorm is an S-PLUS extension.

vecnorm <- function(x, p=2) sum(x^p)^(1/p)

will do almost all of what vecnorm does, if not as fast as the internal
function, but do you need the speed?  I at least thought vecnorm was not a
priority for R.