MATLAB to Python tutorial – Part 1 – arrays and plotting

A quick tutorial for those who are transitioning from MATLAB to Python using NumPy for arrays and matplotlib for plotting.


Justin Lane says:

Nice! Thanks for this, I’ll have to watch the others!
I’ve been looking to move a lot of code from matlab to python and looks like I finally found the IDE for it. Don’t know why I never came across this before.

Christopher Harris says:

Finally a clear example, thank you!

Juan Pablo Aguilar says:

Finally !!! Someone that actually proved that Python is as easy as Matlab.
Thank you very much !!!!

VANI SHREE V 12MSE0084 says:

thank you sir for this wonderful video, it helped me a lot. i m struggling to convert a python code in to matlab. can you pls help me to do this sir, here is my coding
import cv2
import numpy as np

image1 = cv2.imread(‘tablet.jpg’);
image2 = cv2.imread(‘tablet1.jpg’);

difference = cv2.subtract(image1, image2);

result = not np any(difference) if difference is all zeros it will return False

if result == True
fprint(‘images are the same’);
cv2.imwrite(‘result.jpg’, difference)
fprint(‘images are different’);

please help me sir.

thanks with regards

 Write a comment


Do you like our videos?
Do you want to see more like that?

Please click below to support us on Facebook!