Going on ten years (eep!). ML (as I’ll call it) and I got together in grad school. At the time it seemed like a good match. Oh, I suppose it was never exactly true love. I guess ML didn’t always treat me right… for example, there was this whole vectorization thing whenever you wanted to do anything quickly. Lame, right? But I learned to live with it. And once you get used to a partner’s quirks, it’s really hard to get out of the relationship. Really hard to think you’re going to have to learn a whole other set of quirks if you try again with another language. And of course there are the other ones out there that are even worse than your current partner. I watched my friend and his ups and downs with C, and I said, no thanks – C seems even less suited for me than ML. I mean, C seemed nice enough, don’t get me wrong, rather nicer than ML all things considered, but wow, so high-maintenance!
ML and I stuck together as I started working, though I did start to be good friends with C++ at the time as well. Things went from okay to worse. I realized ML did not encourage me to be a good code writer, but rather encouraged bad habits. This was okay in grad school, but now that I wasn’t in school anymore and having to share code with others it was kind of hindering my other relationships. And things that should be easy were sometimes very hard to do. And I was noticing more and more that communication between us was… difficult. Something would go wrong and it was often pretty hard to read in between the lines, or even on the lines, to see what was to blame. It was getting pretty strained between us. My relationship with C++, even though it never really impinged on my relationship with ML – they filled two separate functions in my life – showed me even more the flaws with ML.
Friends noticed ML had some major flaws. My best friend [mr. hunter] tried to gently persuade me I should leave ML. He talked about how he knew of others, Perl or Python, that might be better for me. He fixed me up on a date with Perl but it never really worked out between us. I guess it was hard for me to let go of ML and I never got to know Perl well enough.
Finally, another friend – not even a close one – sat me down and read me the riot act. He told me all the reasons why ML sucked, how it was treating me badly, how it was all wrong for me. He all but forced me into a blind date with Python, whom he thought would be a perfect fit.
And… I went on a date with Python. And we totally clicked. And it was awesome. It was such a relief to be with someone who was okay with, who even encouraged for loops! Who was relaxed and low-maintenance, but at the same time not wedded to an annoying style! Who didn’t require you to spend half your time figuring out how to squeeze variables into ill-fitting matrix containers so you could run things in a vectorized way! Things seemed so easy with Python! Oh, sure, we had a little spat about shallow copying vs. aliasing, but once we got that ironed out things were just blissful.
And yet ML and I are still together, even though I’m now infatuated with Python. I just can’t cut the ties totally with ML – I’ve got a project where ML is necessary, you know how it is… its friends are my project managers, and all that… and it is really good at plotting, I’ll give it that. And gosh, it has been ten years… you know, that’s a significant part of my life invested in ML!
What should I do? (Okay, that was tongue in cheek. I couldn’t resist the end of the relationship analogy. What I’ll do is finish up my project with the PM who really wants me to use Matlab and then use Python for the one that I am managing. And… okay… maybe keep Matlab around for plotting things quickly and for two-line quick things.)