Closed glass-w closed 2 years ago
@jaimergp:
I've now added a new VisPymol
class that handles rendering images of PDB files returned from fingerprint_writepdb
. This is cleaner than having example PyMol scripts floating around.
@glass-w the missing residue 163 is now present, added the protonation fix as described in this plip issue.
I've adapted plipify.visualization.fingerprint_table
to take an optional plipify.core.Structure
object to add one letter residue names. This produces a table that looks like this:
I've also added colour blind friendly colours and to only plot necessary legend names / colours.
@jaimergp I'm unsure why this isn't passing the CI lint checks, when I run Black
locally I don't see any errors in plipify.visualization
Are you using the same version as CI? This is what is being installed now:
Collecting black
Downloading black-21.7b0-py3-none-any.whl (141 kB)
The table looks awesome btw :) Thanks!
Yes, this is what I'm using in my environment:
# Name Version Build Channel
black 21.7b0 pyhd8ed1ab_0 conda-forge
Mm, are you using the same options? e.g. black -l 99 plipify --exclude plipify/_version.py
?
@glass-w the new fingerprint table is AWESOME!
@glass-w could you check one tiny thing for me. In this cell:
Using the methoxy ligand as an example
TODO need to adapt view to use the wH structure
from plipify.core import Structure
methoxy = Structure.from_pdbfile(path="./data/Mpro/aligned/Mpro-P0157_0A/Mpro-P0157_0A_bound_chainA.pdb") # methoxy = selected_structure
We are still using the unprotonated structure, could you run it with the preprocessed structure (you can simply uncomment the methoxy= selected_structure
comment), but the pymol view needs to be updated then and I'm not fully aware how you selected the coordinates.
Check out this pull request on
See visual diffs & provide feedback on Jupyter Notebooks.
Powered by ReviewNB
Superseded by #14
Description
This PR adds a new function to write PDB files per interaction type obtained by
plipify
as well as writing a "total interactions" PDB. This also adds a new class to make PyMol images.Todos
plipify.core.Structure
PyMol
scripts~ AddPyMol
image making classQuestions
Structure._path
, should we have a separate attribute here, something likeStructure.get_file
instead?nglview
style (i.e. with "bonds" between interaction partners with different colours etc). This could either be done in aPyMol
script after structure generation or within the PDB file itself withMDAnalysis
.Status