Skip to content
Prev 206378 / 398506 Next

advice/opinion on "<-" vs "=" in teaching R

On 15-Jan-10 04:06:55, Rolf Turner wrote:
Yes, water flows down-hill -- unless we build control structures ...
There is at least one context where the distinction must be
preserved. Example:

  pnorm(1.5)
  # [1] 0.9331928
  pnorm(x=1.5)
  # Error in pnorm(x = 1.5) : unused argument(s) (x = 1.5)
  pnorm(x<-1.5)
  # [1] 0.9331928
  x
  # [1] 1.5

Ted.

--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding at manchester.ac.uk>
Fax-to-email: +44 (0)870 094 0861
Date: 15-Jan-10                                       Time: 06:57:16
------------------------------ XFMail ------------------------------