[R] modifying a vector

ripley@stats.ox.ac.uk ripley at stats.ox.ac.uk
Sun Jun 30 15:18:22 CEST 2002


On Sun, 30 Jun 2002 Bill.Venables at cmis.csiro.au wrote:

> Peter Dalgaard notes:

(Quoting Tony Rossini)
> > > Note that "_" is assignment in S (and hence R, sigh...).
> >
> > Soon to be deprecated, though... (but it will probably take a while
> > before we can reintroduce it as part of variable names).
> >
> 	[WNV]   Indeed it may, so much so that I am surprised such a change
> is even on the agenda.  We may agree that using "_" a the assignment
> operator can make code difficult to read, but many people do use it, and
> often with some enthusiasm.  It looks a bit to me like unscrambling the egg.
> Let me be clear about this: I really do dislike the thing and I'm not about
> to argue that it should be left untouched.   I'm just very surprised there
> isn't an enormous howl of protest already...

That's because 1.6.0 is not due for release until September or so: `_' is
already deprecated in R-devel, but few people use the bleeding-edge
version.  I don't see underline becoming valid in a syntactic name before
2.0, though.

> 	Are we also about to allow spaces in names and the "=" sign as yet
> another alternative form of the left assignment operator, as in S4?  Should
> be even more interesting.

Have `we' been sleeping in class?   From the NEWS for 1.4.0:

    o	The operator "=" is now allowed as an assignment
	operator in the grammar, for consistency with other languages,
	including recent versions of S-PLUS. [...]

(and those interested please read the ... or help("=")).

As for spaces in names, there is an intention to allow quoted non-standard
names more widely acceptable, including in formulae.

-- 
Brian D. Ripley,                  ripley at 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-help 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-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list