0

I tried to install matplotlib by command line:

sudo env 'PATH=$PATH:/home/lukasz/.local/bin' pip install matplotlibpip install --upgrade setuptools

But this error occured:

sudo env 'python setup.py egg_info" failed with error code 1

I was following steps from pip install returns "python setup.py egg_info" failed with error code 1 but i had error with command

pip install --upgrade setuptools: PermissionError: [Errno 13] Permission denied: '/usr/lib/python3/dist-packages/__pycache__/easy_install.cpython-35.pyc.

What can I do next?

sniperd
  • 4,535
  • 6
  • 26
  • 40
L Pawlak
  • 1
  • 1
  • Have you tried running that last command with sudo? It seems you have sudo access given you were using it in previous comamnds. – Mihai Chelaru May 14 '18 at 14:42

3 Answers3

0

I don't know if this will help achieve what you want, but try:

sudo pip3 install matplotlib

On the command line.

Biomage
  • 344
  • 2
  • 15
0

try this:

 sudo -H pip3 install --upgrade setuptools

and then:

> sudo apt install libfreetype6-dev pkg-config

And then:

> pip3 install --user matplotlib

or:

> sudo -H pip3 install matplotlib

I just installed it following the above steps.

Mani Shirvani
  • 178
  • 1
  • 8
0

Try it, It works for me:

sudo apt-get install python-matplotlib
Josh Lee
  • 161,055
  • 37
  • 262
  • 269
VipinSC
  • 11
  • 4