Matlab has many problems as a programming language. Some could be easily fixed, some probably not. Some are very real and important issues that discourage advanced programmer from using it. This is one of the reasons why a large number of people are migrating to Python.
I still believe Matlab is very valuable for a lot of reasons. First, Matlab has reached the “Critical Mass”, especially in my field. Second, its private and commercial origin is both its default (cost of the software) and advantage as it enforces a uniform and properly organized structure to the whole system. The recent and important progress of Python (thanks to Numpy and Scipy packages) is in all cases a good thing as it diversifies the computational offer to scientists. The years of Matlab hegemony seem to be coming to an end.
Still, I would like to discuss here these annoyances that convinced people to move over to Python. I will probably follow this line in a couple posts. Eventually, I will suggest a solution around if I find one.
I recently came across one of them that is good to keep in mind.
You probably all know that whatever Matlab is doing, you can stop it using CTRL+C.
Let’s assume you have this code running :
try ..... catch ..... end
This is a very simple error management system as I recently talked about. Well, you would be surprised, but if your user press CTRL+C while doing a try statement, Matlab just stops here. It does not go to your catch as you would expect. This is a design choice from Mathworks.
Fine, but this is an annoyance when you program a GUI, for instance. If you disable your GUI during calculations, there is no way to turn it back if CTRL+C is pressed. You have to start the whole thing again!