Re: [Rd] "+" for character method...

2006-08-27 Thread Duncan Murdoch
On 8/27/2006 9:44 PM, Allen S. Rout wrote: > Duncan Murdoch <[EMAIL PROTECTED]> writes: > >> According to Wikipedia, the "+" operator is used for concatenation in >> BASIC, Pascal, Delphi, Javascript, Java, Python, C++ and Ruby. These >> are probably the most commonly used modern languages othe

Re: [Rd] "+" for character method...

2006-08-27 Thread Latchezar Dimitrov
I love PERL then ... ;-) Latchezar Dimitrov > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Allen S. Rout > Sent: Sunday, August 27, 2006 9:45 PM > To: r-devel@stat.math.ethz.ch > Subject: Re: [Rd] "+" for character m

Re: [Rd] "+" for character method...

2006-08-27 Thread Allen S. Rout
Duncan Murdoch <[EMAIL PROTECTED]> writes: > According to Wikipedia, the "+" operator is used for concatenation in > BASIC, Pascal, Delphi, Javascript, Java, Python, C++ and Ruby. These > are probably the most commonly used modern languages other than C (which > has no concatenation operator)

Re: [Rd] "+" for character method...

2006-08-27 Thread Latchezar Dimitrov
> -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Thomas Lumley > Sent: Sunday, August 27, 2006 6:22 PM > To: John Chambers > Cc: R-devel@r-project.org > Subject: Re: [Rd] "+" for character method... > > On

Re: [Rd] "+" for character method...

2006-08-27 Thread Duncan Murdoch
Thomas Lumley wrote: > On Sat, 26 Aug 2006, John Chambers wrote: > > >> Well, two comments, in two non-compatible directions. >> >> 1. I have to say that I find the idea of using "+" to paste character >> strings together aesthetically ugly. >> > > Hear, hear! > > In a language where you c

Re: [Rd] "+" for character method...

2006-08-27 Thread Thomas Lumley
On Sat, 26 Aug 2006, John Chambers wrote: > Well, two comments, in two non-compatible directions. > > 1. I have to say that I find the idea of using "+" to paste character > strings together aesthetically ugly. Hear, hear! In a language where you can define new binary operators easily making th

Re: [Rd] "+" for character method...

2006-08-26 Thread Latchezar Dimitrov
M > To: Bill Dunlap > Cc: R-devel@r-project.org; Duncan Murdoch; Martin Maechler > Subject: Re: [Rd] "+" for character method... > > Well, two comments, in two non-compatible directions. > > 1. I have to say that I find the idea of using "+" to paste > char

Re: [Rd] "+" for character method...

2006-08-26 Thread Gabor Grothendieck
There are several problems with %+% : - %whatever% should be open for use by the user and if R starts taking them over they won't be - %+% is ugly - %+% is not consistent with other languages (the C-based syntax of R is supposed to leverage off one's knowledge of other languages) Personally

Re: [Rd] "+" for character method...

2006-08-26 Thread Duncan Murdoch
On 8/26/2006 10:26 AM, John Chambers wrote: > Well, two comments, in two non-compatible directions. > > 1. I have to say that I find the idea of using "+" to paste character > strings together aesthetically ugly. > > IMO, one thing that makes functional object-based languages attractive > is t

Re: [Rd] "+" for character method...

2006-08-26 Thread Gabor Grothendieck
On 8/26/06, John Chambers <[EMAIL PROTECTED]> wrote: > 1. I have to say that I find the idea of using "+" to paste character > strings together aesthetically ugly. > > IMO, one thing that makes functional object-based languages attractive > is that the generic function retains a consistent _functi

Re: [Rd] "+" for character method...

2006-08-26 Thread John Chambers
Well, two comments, in two non-compatible directions. 1. I have to say that I find the idea of using "+" to paste character strings together aesthetically ugly. IMO, one thing that makes functional object-based languages attractive is that the generic function retains a consistent _function_,

Re: [Rd] "+" for character method...

2006-08-25 Thread Duncan Murdoch
On 8/25/2006 6:52 PM, Bill Dunlap wrote: >>> >> There have been propositions to make "+" work in S (and >>> >> R) like in some other languages, namely for character >>> >> (vectors), >>> >> >>> >> a + b := paste(a,b, sep="") >>> ... >>> yes. I think however if we keep speed and

Re: [Rd] "+" for character method...

2006-08-25 Thread Bill Dunlap
> > >> There have been propositions to make "+" work in S (and > > >> R) like in some other languages, namely for character > > >> (vectors), > > >> > > >> a + b := paste(a,b, sep="") > > ... > > yes. I think however if we keep speed and clarity and catching > > user errors all

Re: [Rd] "+" for character method...

2006-08-25 Thread Duncan Murdoch
On 8/25/2006 4:55 PM, Martin Maechler wrote: >> "Duncan" == Duncan Murdoch <[EMAIL PROTECTED]> >> on Fri, 25 Aug 2006 13:18:42 -0400 writes: > > Duncan> On 8/25/2006 12:31 PM, Martin Maechler wrote: > >> This thread remains me of an old recurring (last May!) > >> theme whic

Re: [Rd] "+" for character method...

2006-08-25 Thread Prof Brian Ripley
1) I'd like to take a look at what is involved before commenting on efficiency issues. They may not be what I thought they were (or at least, being generic at all may be so big a hit that a few more cases may be immaterial). 2) This + is clearly not commutative. 3) + is part of group generic.

Re: [Rd] "+" for character method...

2006-08-25 Thread Martin Maechler
> "Duncan" == Duncan Murdoch <[EMAIL PROTECTED]> > on Fri, 25 Aug 2006 13:18:42 -0400 writes: Duncan> On 8/25/2006 12:31 PM, Martin Maechler wrote: >> This thread remains me of an old recurring (last May!) >> theme which maybe fits well to Friday late afternoon... >>

Re: [Rd] "+" for character method...

2006-08-25 Thread Duncan Murdoch
On 8/25/2006 12:31 PM, Martin Maechler wrote: > This thread remains me of an old recurring (last May!) theme > which maybe fits well to Friday late afternoon... > > There have been propositions to make "+" work in S (and R) > like in some other languages, > namely for character (vectors), >

[Rd] "+" for character method...

2006-08-25 Thread Martin Maechler
This thread remains me of an old recurring (last May!) theme which maybe fits well to Friday late afternoon... There have been propositions to make "+" work in S (and R) like in some other languages, namely for character (vectors), a + b := paste(a,b, sep="") IIRC, when this theme cam