From MATLAB To Python

Posted on


For many years MATLAB has been my primary tool for prototyping algorithms, because of its rich set of optimization functions and the AI tool box it has proven to be a valuable tool to have. However, It is not cheap and if you do not have a company to pay for license or attend a university that provides you with a license then you will have to find an alternative.

MATLAB is not a programming language rather its a tool that has as part of its framework a programming language called M language, this language has a lot of quirks and takes some getting use to, the other issue I found with MATLAB is that the functions while well documented do not seem to follow a standard in terms of parameters; on the whole while MATLAB is a good tool for prototyping and is used a lot in engineering and medical fields which are my core domain; However,I am forced to look for a cheaper/free alternative that will give me as much if not more tools than MATLAB now provides.

Python to the rescue:

Python is powerful… and fast;
plays well with others;
runs everywhere;
is friendly & easy to learn;
is Open

All these wonderful things make Python a big contender for my MATLAB replacement.

The first thing we want to do is install Python.
Next install my favurite Python IDE PyCharm
Create a new Python Project using PyCharm
Python project

How do we add packages to our project?
Python is nothing without its packages and two of my favourites are numpy and scipy. To add these packages simply download the Anaconda distribution and configure it to be your default python implementation.


And here is my first piece of python code as taken from the python website🙂


All I need now is a good Python book and 2-4 months to delve into the language. Stay tuned for more posts on my Python journey. Happy coding!!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s