On Nov 21, 2007 10:27 AM, Simon Urbanek <[EMAIL PROTECTED]> wrote: > > On Nov 21, 2007, at 1:11 PM, Byron Ellis wrote: > > > I actually like = because I screw myself over with things like > > b[b<-1]=-1 on a regular basis. :-) > > > > Of course, I also manage to screw myself over with (b = 1 | x == 2) so > > perhaps there's simply no hope for me... Perhaps the Smalltalk-style > > assignment ':='.... > > > > Wasn't that ALGOL, really? ;) I must agree that I like it as well (and > surprisingly it's still compatible with R's syntax - just in case we > don't have enough assignment operators already) - but then, I'm one of > those poor kids who grew up on Pascal, so I don't count ;). [Still, I > wouldn't go as far as to re-introduce begin/end :P]
I always thought it was a common mapping for the 3270's left arrow key (I also always assumed that's where S' <- operator came from) when PC-style keyboards started dominating, the same as the ^ operator in Smalltalk is a mapping to the up arrow key on the original keyboard. I too grew up on Pascal (Turbo Pascal 3. Imagine my disappointment in Anders Hejlsberg and C#, though it's now finally starting to Suck Less). > > Cheers, > Simon > > > > > On Nov 21, 2007 8:45 AM, John Chambers <[EMAIL PROTECTED]> wrote: > >> ??? ? ???Simon Urbanek wrote:?James,?????On Nov 21, 2007, at 8:22 > >> AM, James Milks wrote:??????> The '=' sign can be used in place > >> of?'<-'. That's the only shorthand ?> I know for R.??> ??> ? ???? > >> That's not a shorthand. `=` and `<-` are semantically different in? > >> R.????Well, not really :-)????It's true that the "=" operator won't > >> be displayed as "<-", which ?I?agree was the original point. But > >> both assignment operators map ?into?the same internal C code, if > >> you dig into the implementation.????The "=" operator was added in > >> S4 to assuage folks with C/Java/awk ?....?backgrounds who didn't > >> care for the weird assignment operator. ?But?"real" S and R > >> users still seem to like "<-" better.????Alexy was asking > >> presumably about shorthands that you press/type in ?the?R Mac GUI > >> which will result in `<-` being produced and those ?are?<Alt><-> > >> (this comes from Emacs' "_" shortcut which you?type on US ?keyboard > >> as <Shift><-> but given that the?character _ is often used ?these > >> days, we c! > >> reated a variant where you?use <Alt> instead of <Shift>) ?and > >> <Ctrl><=>?(this one is simply a play on the equal sign and should ? > >> make sense on?other keyboards, too). The last shorthand I ? > >> mentioned?(<Alt>+<=>) is a direct translation of the sign (which? > >> you ?get in other programs when pressing <Alt><=>) into R?code.????? > >> Cheers,??? > >> Simon > >> ?????????------------------------------------------------------------------------??_______________________________________________ > >> ?R-SIG-Mac mailing [EMAIL > >> PROTECTED]://stat.ethz.ch/mailman/listinfo/r-sig-mac? > >> ??????? > >> [[alternative HTML version deleted]] > >> > >> > >> _______________________________________________ > >> R-SIG-Mac mailing list > >> [email protected] > >> https://stat.ethz.ch/mailman/listinfo/r-sig-mac > >> > >> > > > > > > > > -- > > Byron Ellis ([EMAIL PROTECTED]) > > "Oook" -- The Librarian > > > > > > -- Byron Ellis ([EMAIL PROTECTED]) "Oook" -- The Librarian _______________________________________________ R-SIG-Mac mailing list [email protected] https://stat.ethz.ch/mailman/listinfo/r-sig-mac
