{ "cells": [ { "cell_type": "markdown", "id": "98a65e59-67fa-492c-89ce-9e18fc12fed3", "metadata": {}, "source": [ "# Virtual Screening\n", "\n", "This notebook aims to demonstrate how to use AutoDock Vina (via Smina) and Ledock to dock multiple molecules in the same protein target and binding site. \n", "\n", "## Content of this notebook\n", "\n", "1. Feching system and cleanup\n", "2. System Visualization \n", "3. Docking with Smina\n", " - Receptor preparation\n", " - Ligand preparation\n", " - Docking box definition\n", " - Docking\n", " - 3D visualization of docking results\n", "4. Docking with LeDock\n", " - Receptor preparation\n", " - Ligand preparation\n", " - Docking box definition\n", " - Docking\n", " - DOK results file conversion to SDF\n", " - 3D visualization of docking results" ] }, { "cell_type": "code", "execution_count": 1, "id": "15b2c953-805a-4ff9-8095-a612df9629cd", "metadata": {}, "outputs": [], "source": [ "from pymol import cmd\n", "import py3Dmol\n", "\n", "from openbabel import pybel\n", "\n", "from rdkit import Chem\n", "from rdkit.Chem import AllChem\n", "\n", "import sys, os, random\n", "sys.path.insert(1, 'utilities/')\n", "\n", "from utils import getbox, generate_ledock_file, dok_to_sdf\n", "\n", "import warnings\n", "warnings.filterwarnings(\"ignore\")\n", "\n", "%config Completer.use_jedi = False" ] }, { "cell_type": "code", "execution_count": 2, "id": "d8d7b03b-9b00-4ef8-947f-eefb350825db", "metadata": {}, "outputs": [], "source": [ "os.chdir('test/Virtual_Screening/')" ] }, { "cell_type": "markdown", "id": "c7fe56ca-6510-4892-9b7f-fd713744663d", "metadata": {}, "source": [ "## 1. Feching system and cleanup\n", "\n", "Implementing Pymol is a simple way to download PDB structures. The user can launch this or any other Jupyter Dock's protocol by providing his or her own files." ] }, { "cell_type": "code", "execution_count": 3, "id": "80ac6b11-21f7-4a27-82a5-e59e5ba3c0b1", "metadata": {}, "outputs": [], "source": [ "cmd.fetch(code='1X1R',type='pdb1')\n", "cmd.select(name='Prot',selection='polymer.protein')\n", "cmd.select(name='GDP',selection='organic')\n", "cmd.save(filename='1X1R_clean.pdb',format='pdb',selection='Prot')\n", "cmd.save(filename='1X1R_GDP.mol2',format='mol2',selection='GDP')\n", "cmd.delete('all')" ] }, { "cell_type": "markdown", "id": "bc5119bd-ab15-4952-accd-806dcba8df07", "metadata": {}, "source": [ "## 2. System Visualization\n", "\n", "A cool feature of Jupyter Dock is the posibility of visualize ligand-protein complexes and docking results into the notebbok. All this thanks to the powerful py3Dmol. \n", "\n", "Now the protein and ligand have been sanitized it would be recomended to vissualize the ligand-protein reference system." ] }, { "cell_type": "code", "execution_count": 4, "id": "1d90faf9-b7c1-4808-b5cc-c37e1849a2cf", "metadata": {}, "outputs": [ { "data": { "application/3dmoljs_load.v0": "
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n jupyter labextension install jupyterlab_3dmol
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n",
" jupyter labextension install jupyterlab_3dmol
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n jupyter labextension install jupyterlab_3dmol
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n",
" jupyter labextension install jupyterlab_3dmol
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n jupyter labextension install jupyterlab_3dmol
You appear to be running in JupyterLab (or JavaScript failed to load for some other reason). You need to install the 3dmol extension:
\n",
" jupyter labextension install jupyterlab_3dmol