Function scale (PR#2209)

Duncan Murdoch murdoch@stats.uwo.ca
Thu, 24 Oct 2002 13:07:29 -0400


On Thu, 24 Oct 2002 11:55:07 -0400, you wrote in message
<D7A3CFD7825BD6119B880002A58F06C20149D11A@groexmb02.pfizer.com>:

>Generally speaking, I think it is poor design for software to 'surprise' the
>user, even if documentation specifies the surprising activity...   

I agree, but I don't think it's clear what would be unsurprising
behaviour here.

If you ask for scaling but no centering, how should the scale be
estimated?  

1. To me the obvious scale is sqrt(sum(x^2)/n).
2. R and S-PLUS use sqrt(sum(x^2)/(n-1)).
3. I think the original poster was suggesting
sqrt(sum((x-mean(x))^2/(n-1)) (but it wasn't stated explicitly, so I'm
not sure).

In a case like this, I'd say backwards compatibility wins.

Duncan Murdoch
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._