close

[Solved] python error: no module named pylab

Hello Guys, How are you all? Hope You all Are Fine. Today I get the following error python error: no module named pylab in python. So Here I am Explain to you all the possible solutions here.

Without wasting your time, Let’s start This Article to Solve This Error.

How python error: no module named pylab Error Occurs?

Today I get the following error python error: no module named pylab in python.

How To Solve python error: no module named pylab Error ?

  1. How To Solve python error: no module named pylab Error ?

    To Solve python error: no module named pylab Error That said, I would recommend using the version of python in the repositories as I think it is up to date with the current version of python (2.7.3).

  2. python error: no module named pylab

    To Solve python error: no module named pylab Error That said, I would recommend using the version of python in the repositories as I think it is up to date with the current version of python (2.7.3).

Solution 1

I installed python-numpy python-scipy python-matplotlib, but it didn’t work for me and I got the same error. Pylab isn’t recognized without matplotlib. So I used this:

from matplotlib import pylab
from pylab import *

and worked for me.

Solution 2

You’ll need to install numpy, scipy and matplotlib to get pylab. In ubuntu you can install them with this command:

sudo apt-get install python-numpy python-scipy python-matplotlib

If you installed python from source you will need to install these packages through pip. Note that you may have to install other dependencies to do this, as well as install numpy before the other two.

That said, I would recommend using the version of python in the repositories as I think it is up to date with the current version of python (2.7.3).

Summery

It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you? Thank You.

Also, Read