I have a similar anecdote: I was brought in on a project where a group of terrorists implemented a solution for a TSP-like problem directly in R. We eventually replaced that thing with OR-Tools.
I have a similar anecdote: I was brought in on a project where a group of terrorists implemented a solution for a TSP-like problem directly in R. We eventually replaced that thing with OR-Tools.
I keep wondering if I should learn the Python data science ecosystem at some point but it just seems like a waste of time. One of my personal projects is written in Python but calls into R for statistics/plotting.
The language itself however, incredibly cursed.
I think of MATLAB, Mathematica, R, and Python together as "practitioner's languages". These are languages that are designed from the core to be highly productive to a specific kind of technical worker (in the sense of developer velocity).
MATLAB for engineering. Mathematica for mathematics. R for statistics. Python for software engineering.
You could also say "Python for ML", of course, and that would be true, but Python is also used for general purpose programming much more than the other three. I think that "Python for software engineering" is more correct.
I think that each of the languages is shaped to the way that its users think about the problems that they want to solve with it.
MATLAB is shaped around linear algebra. Mathematica is a term-rewriting system. R has lots of magic around data and scopes to make the surface syntax for stats nice. Python is shaped like a traditional OOP language but with a pseudocode-like syntax and hooks so that libraries can act magically.
This is kinda half-baked, I'm trying to express this for the first time. But essentially I think that Python is what you get when you have real programmers (^TM) try to create the programming equivalent of something like MATLAB, Mathematica, and R.
And so of course ML, which is a field dominated by real programmers, adopted Python in order to create their ecosystem.
> I think that Python is what you get when you have real programmers (^TM) try to create the programming equivalent of something like MATLAB, Mathematica, and R.
I think this is a better description of Julia tbh, at least relative to MATLAB.
Why would you say that?
I would never write a full stack application in R. Terrible maintainability.
Glad to hear the agreement. Little small projects are so fun. Stadium-sized pools full of spaghetti less so!
Statistical Rethinking by McElreath is really what finally got me to see the value of R.
You can find the python versions of the class and they are certainly not better.
A full application in R really makes absolutely no sense.
You're 100% right that R is great for data scientists (my background) for frontier level academic implementations as well as toy/simple models. It's generally a poor runtime for computation and suffers from much of the same issues as Python for data quality and typing. Python is better for battle-hardened type stuff, has better debugging tools for certain.
R _can_ be done well, but the juice isn't worth the squeeze typically.
Considerations like repeatable procedures, reliable package heirarchies, etc. were clearly and more or less politely Not Interesting. I spent several years with one of my tasks being an attempt to get the R package universe into Gentoo, and later to RPM packages.
I wouldn't say the R devel community was rude about it, but the systems-administration view of how to maintain the language was just not on their radar.
At the time I was trying to provide a reliable taxonomy of packages to a set of research machines at a good sized university. Eventually, I gave up on any solution that involved system package managers, or repeatability. :)
So if you're a researcher driving your own train, R is freakin' FANTASTIC. If you're the SA attempting to let that researchers' department neighbors do the same thing on their workstations, anticipate fun.
Another: R can’t losslessly represent JSON because 1 and [1] are identical. That’s a float (well, float vector) literal by the way, the corresponding int literal is 1L, though ints are very prone to being silently converted to float anyway.