[chimerax-users] using pandas

Tom Goddard goddard at sonic.net
Thu Jun 10 21:47:23 PDT 2021


Hi Ilse,

On Windows I run a Command Prompt as administrator to have permission to modify  the installed ChimeraX and use

> cd C:\Program Files\ChimeraX-1.2.5\bin
> .\python.exe -m pip install pandas

And then I can use "import pandas" in the ChimeraX shell (menu Tools / General / Shell)  without errors.

Or in a Command Prompt that is not run as administrator I run

> cd C:\Program Files\ChimeraX-1.2.5\bin
> .\ChimeraX-console.exe -m pip install pandas --user

and again pandas installs fine and imports in ChimeraX.

Definitely we should add an easy way to do this in ChimeraX without the Command Prompt rigamarole, like a ChimeraX command "pip install pandas".  But we don't have that right now.  Sadly the Python pip package does not have an API to do installs using a function call -- really poor design.  But probably we can work around that.

   Tom


> On Jun 9, 2021, at 10:27 AM, Tom Goddard <goddard at sonic.net> wrote:
> 
> Hi Ilse,
> 
>   ChimeraX distributions include Python so you just want to install pandas into the ChimeraX Python.   This involves running the ChimeraX Python and using pip install. Here is how I do that on Mac.  
> 
> $ ~/Desktop/ChimeraX.app/Contents/bin/python3.8 -m pip install pandas
> 
> On Windows or Linux it would be similar.  We should have a ChimeraX command to install PyPi packages but don't have that yet.
> 
> 	Tom
> 
> 
>> On Jun 9, 2021, at 3:09 AM, Lagerwaard, I.M. (Ilse) via ChimeraX-users <chimerax-users at cgl.ucsf.edu <mailto:chimerax-users at cgl.ucsf.edu>> wrote:
>> 
>> Hello everyone,
>>  
>> Is it possible to use the pandas package in ChimeraX? I tried opening a Python script containing the line ‘import pandas’, but I get the error: ‘ModuleNotFoundError: No module named 'pandas'’.
>>  
>> Kind regards,
>> Ilse
>> _______________________________________________
>> ChimeraX-users mailing list
>> ChimeraX-users at cgl.ucsf.edu <mailto:ChimeraX-users at cgl.ucsf.edu>
>> Manage subscription:
>> https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users <https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://plato.cgl.ucsf.edu/pipermail/chimerax-users/attachments/20210610/37bc76d6/attachment.html>


More information about the ChimeraX-users mailing list