[R] the less-than-minus gotcha
Rolf Turner
r.turner at auckland.ac.nz
Mon Feb 2 12:58:10 CET 2015
On 02/02/15 14:26, Steve Taylor wrote:
> All the more reason to use = instead of <-
Couldn't agree less, Steve. The "<-" should be used for assignment. The
"=" sign should be reserved for handling function arguments in the
"name=value" form. Doing anything else invites confusion and
occasionally chaos.
Lots of examples have been given in the past involving syntax of the
form foo(x = y) and foo(x <- y).
cheers,
Rolf
--
Rolf Turner
Technical Editor ANZJS
Department of Statistics
University of Auckland
Phone: +64-9-373-7599 ext. 88276
Home phone: +64-9-480-4619
More information about the R-help
mailing list