Live data from Hacker News

Matlab is oversold as a general-purpose language

abandonmatlab.wordpress.com

71–80 of 104 posts

Re: Matlab is oversold as a general-purpose language

#71

Earlier quoted context omitted.

I could not agree more with every word you have written here. I would like to add that scientists are neither averse to change, nor too lazy to learn new tools. However, they typically only care about the solution to their problem, not about programming in general. It is thus futile to try to convince them to use a different tool from a programmers' point of view--you need to convince them by showing them how much si…

The thing is it isn't just about solving their problems. The tough thing is to convince them how much it would help the community as a whole. I have tried many times to download some PhDs code and attempt to get it to compile. Usually it can be done after a lot of effort and tweaking. But it would be beneficial for science if code was treated as important as the paper itself.

> But it would be beneficial for science if code was treated as important as the paper itself.

One could argue that it isn't. In science, the concept is usually more important than the implementation.

But I totally agree. Scientific code tends to be awful and I wish I knew what to do about that.

Re: Matlab is oversold as a general-purpose language

#72
post #23

Earlier quoted context omitted.

try python. it is much more powerful in almost every sense. And it is not easy to write crappy code in python.

Last I looked, vector and matrix handling was extremely clunky and tacked on in Python.

Can you be more specific?

Re: Matlab is oversold as a general-purpose language

#73
post #62

Earlier quoted context omitted.

I could not agree more with every word you have written here. I would like to add that scientists are neither averse to change, nor too lazy to learn new tools. However, they typically only care about the solution to their problem, not about programming in general. It is thus futile to try to convince them to use a different tool from a programmers' point of view--you need to convince them by showing them how much si…

I've had an unfortunate opportunity to have to help out a cousin's girlfriend with python. She's studying informatics and it's their introductory course in programming (recently switched from pascal). But python has really too many abstract constructs to explain easily. One example they had was using the for loop. I don't know python, but from the examples and exercises the professor gave them, it doesn't seem to hav…

Totally agree. I learned C first, then C++. I wouldn't have it any other way. The top-down approach means you truly understand nothing until a year or so down the line. The bottom up approach lets you fully grasp the small world you've been exposed to. And as more concepts are introduced your world expands. At no point are you just left wondering WTF are these magic keywords doing.

Re: Matlab is oversold as a general-purpose language

#74
In a crowded market, the sales pitch has to anticipate and overcome "negatives." Thus, MATLAB has to be marketed as a "real programming language" to overcome the fear that it will prove inadequate for some task in the future -- especially when you had to beg and plead for the money to buy a license.

And amateurs (including me) don't always see the difference between the language and the libraries, so the demand for a "real programming language" results in a huge bloated product festooned with every possible bell and whistle.

I wouldn't have a problem with a tool that falls short of completeness (Turing- or otherwise) if it's simple and does something useful for me. I love spreadsheets.

Re: Matlab is oversold as a general-purpose language

#75
post #9

Okay, I'll bite on this one. I used matlab quite extensively (for years) in the medical imaging field, as well as other miscellaneous engineering (read: electronics, modeling, FEA. Not web apps) disciplines. I noticed several things about the matlab culture: - In academia, people really do not seem to give a fuck about using the right tool for the job. I used to try to explain to the people in my lab why their softwa…

I more often see the opposite problem in CS academia. People care too much about what tool is best for a job, and as a result nothing is easily interoperable. One grad student writes stuff in Haskell, another one uses OCaml, a third does everything in Python, a fourth uses Common Lisp, and you're lucky if a fifth doesn't use his custom, self-maintained Scheme dialect that he swears is perfectly adapted to the job.

I'm not a big Matlab fan, but I do sometimes envy the areas where there's a default environment everything is expected to plug in to, whether it's Matlab or R or something else (Python, increasingly).

Re: Matlab is oversold as a general-purpose language

#76

The author is totally biased, but that doesn't mean he is wrong. If the bias offends you, you aren't the target audience. I personally have experienced several of the things he rants about, so I know his pain and now as a policy refuse to produce additional IP in that ecosystem. When friends ask me for help, I now send them a python script. The rage doesn't really come from MATLAB (every language has warts); the rage…

I have seen some horrible shit. Terrible, awful, fucked up stupid undocumented code. I have worked in psychophysics shops (go figure). What makes you think it would be any better had they not used MATLAB? I actually like MATLAB. It really excels when used as a glorified calculator and you can plug lots of things into it and have it 'just work' without much fuss. When I worked in a tutoring lab sometimes it was cool t…

> I don't know why it's getting so much hate.

It's a terrible language. One function per file, you need to special case LxMxN matrices where N is variable in the case N=1, can't do myfun()[0:4].

Use it for a while and you will run into painful limitations.

Re: Matlab is oversold as a general-purpose language

#77
post #64
post #53

Earlier quoted context omitted.

In what way is Matlab more feature-complete and polished? With respect to just the actual language Octave is nearly a 1:1 implementation of Matlab, which is an primary goal to stride for and maintain, any differences between the two is considered a bug even.

Graphics in general, handle graphics in particular, and no I'm not kidding. OOP for visualization can't be beat.

So a specific graphics toolkit then? Is it one that is included with Matlab or another toolkit that is necessary to pay in addition for?

Re: Matlab is oversold as a general-purpose language

#78
post #72

Earlier quoted context omitted.

Last I looked, vector and matrix handling was extremely clunky and tacked on in Python.

Can you be more specific?

I'm not the parent commenter but I've used matlab extensively and found Numpy clunky in comparison.

All I ever did in matlab involved matrices (usually differential equations with matrix coefficients and other things of that nature) and matrices are super easy to use in MATLAB:

    A = [1 2 3
        4 5 6];
or

    A = [1 2 3; 4 5 6];
I can input A just like that and it works, try out the python syntax:

    A = array([[1,2,3],[4,5,6]])
And it just goes on from there.

Even if you're doing complicated operations because matrices are the essential building blocks of MATLAB it is easy to use, not so much in python.

I tried building my FEA (finite element analysis) project in python after i finished programming it in matlab it and found it to frustrating to continue.

Re: Matlab is oversold as a general-purpose language

#79
Is there a "Matlab: The good bits" guide out there somewhere? I think a style preference guide, made by an experienced programmer who worked on large matlab codebases would be valuable both for programmers who have to figure out how to work reasonably with Matlab, and the scientists and mathematicians who just don't know any better.

Re: Matlab is oversold as a general-purpose language

#80

Earlier quoted context omitted.

We don't use simulink or anything like that - we just use the typical linear algebra stuff: Markov chains, finding eigenvalues, solving linear systems, etc.

And that's the thing with Matlab, it does the math part really well Maybe R and Numpy are getting better, but try to invert a matrix, find and eigenvalue, find the solution to a polynomial, fit an equation, etc Not to mention the most advanced things outside Matlab

You mean like this? http://docs.scipy.org/doc/numpy/reference/routines.linalg.ht...
Post reply on HN