How to fix ModuleNotFound matplotlib.pyplot error in interactive shell with anaconda virtural enviroment— solved
Jun 13, 2021
# if you have a virtual env you need remove it
conda env remove -n “old_virtual_env_name”
# create a new virtual env
conda create -n conda_env
# activate the virtual env
conda activate conda_env
# because sometimes when we are using anaconda it takes the imports from the normal python installation. So you need
conda install notebook ipykernel
ipython kernel install — user
# install matplotlib
conda install -c conda-forge matplotlib