News for hackers. Stuff that matters.
Re:Advanced R programming by wfunction on Sunday November 17, 2013 @07:00AM (#6748555)
"I haven't used it enough to love, so I'm not at the stage that I am with JavaScript. That is, I know of JavaScript's problems but know of the strengths that sometimes derive from its weirdness."

I'll take a risk and ask: what are these strengths you're talking about that JS has?

Re:Advanced R programming by jnbiche on Sunday November 17, 2013 @08:32AM (#6748814)
I really like the prototypal inheritence -- it's a feature few modern languages use, and yet it's very flexible.
Re:Advanced R programming by felixr on Sunday November 17, 2013 @09:15AM (#6749006)
I think when it comes to inheritance and object-oriented programming, R and JavaScript share the problem that there is not one standard why of doing it. Libraries can and do implement different systems. In JavaScript prototypal inheritance is built-in, but there are also libraries that implement there own way of doing OO. In R you have the S3, S4 and Reference class system, and their are also packages that implement other approaches.

For prototypal inheritance in R you can try the proto package [1].

[1]: http://cran.r-project.org/web/packages/proto/index.html

Re:Advanced R programming by jnbiche on Sunday November 17, 2013 @10:20AM (#6749248)
Interesting that R has a proto package, but to be honest, if I get to the point where I need classes or prototypal inheritance in R, I reach for another tool. R is excellent for exploratory data analysis, but in my (admittedly limited) experience with R, it makes for a poor choice for anything more complex than a small script.
Re:Advanced R programming by danso on Sunday November 17, 2013 @07:11AM (#6748583)
Besides the Stockholm Syndrome?...I think you have me there. It's not that JS doesn't have strengths, it's whether some of its widely derided flaws resulted in happy tradeoffs? I'm banging my head thinking of something specifically (and widely agreed on) but it's early. I guess the same question could be asked of JavaScript...does its exclusively great libraries, such as D3, exist in JS purely because JS is the most popular language for interactivity, rather than because JS was well-suited for such libraries? Probably the former.
Re:Advanced R programming by Bootvis on Sunday November 17, 2013 @08:01AM (#6748721)
I agree with Crockfords sentiment that all the parts of JavaScript that are like Scheme can be considered good.