<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div dir="ltr"></div><div dir="ltr">On Jul 13, 2025, at 04:00, Christoph Kukulies wrote:</div><div dir="ltr"><blockquote type="cite"><br></blockquote></div><blockquote type="cite"><div dir="ltr"><div class="">In a notebook I'm getting:</div><pre class=""><span class="ansi-red-fg">---------------------------------------------------------------------------</span>
<span class="ansi-red-fg">ModuleNotFoundError</span> Traceback (most recent call last)
Cell <span class="ansi-green-fg">In[4], line 2</span>
<span class="ansi-bold ansi-green-intense-fg"> 1</span> <span style="color:rgb(95,135,135)" class="">#%matplotlib inline</span>
<span class="ansi-green-fg">----> 2</span> <span class="ansi-bold" style="color:rgb(0,135,0)">import</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,0,255)">matplotlib</span><span class="ansi-bold" style="color:rgb(0,0,255)">.</span><span class="ansi-bold" style="color:rgb(0,0,255)">pyplot</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,135,0)">as</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,0,255)">plt</span>
<span class="ansi-bold ansi-green-intense-fg"> 3</span> <span class="ansi-bold" style="color:rgb(0,135,0)">import</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,0,255)">numpy</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,135,0)">as</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,0,255)">np</span>
<span class="ansi-bold ansi-green-intense-fg"> 4</span> <span class="ansi-bold" style="color:rgb(0,135,0)">import</span><span style="color:rgb(188,188,188)" class=""> </span><span class="ansi-bold" style="color:rgb(0,0,255)">csv</span>
<span class="ansi-red-fg">ModuleNotFoundError</span>: No module named 'matplotlib'</pre><div class=""><br class=""></div><div class=""><div class=""><br class=""></div>
<font size="1" class=""><span class=""><font face="Menlo" class="">port installed | grep matplotlib<br class=""> py311-matplotlib-inline @0.1.7_0 (active)<br class=""> py313-matplotlib-inline @0.1.7_0 (active)</font></span></font></div></div></blockquote><div><br></div>Have you tried installing the py311-matplotlib port?<br><div><br></div><br><blockquote type="cite"><div dir="ltr"><div class=""><font size="1" class=""><span class=""></span></font><font face="Menlo" class=""><font size="1" class=""><span class="">$ pip install matplotlib<br class=""></span><span class="">Requirement already satisfied: matplotlib in /usr/local/lib/python3.11/site-packages (3.10.3)<br class=""></span><span class=""></span></font></font></div></div></blockquote><br><div>Things in /usr/local are not provided by MacPorts. I recommend you remove what you have installed there to avoid confusion. </div><div><br></div><div>On an Intel Mac items in /usr/local may be provided by Homebrew if you have that installed. If so, I recommend you uninstall it. Use either MacPorts or Homebrew but not both. </div><div><br></div><div>You probably don't want to run "pip install" except when in a virtualenv. When not in a virtualenv, I think "pip install" will install into the system prefix which would interfere with software installed by "the system" (e.g. Homebrew or MacPorts). Instead, install the MacPorts port for the module you want. </div><div><br></div><div><br></div></body></html>