Connect with us


How to perform virtual screening using Pyrx?



How to perform virtual screening using Pyrx?

Pyrx is a bioinformatics tool to perform virtual screening [1]. We previously provided an article on performing simple protein-ligand site-specific docking using Pyrx. In this article, we are going to perform virtual screening using Pyrx.

Here, we are going to dock three ligands with a macromolecule. You can dock multiple ligands.

Downloading Protein

We are going to use the same protein as we have used in our previous docking tutorials, i.e., human serum albumin (HSA). The PDB ID is 2BXA. It is complexed with a compound called 3-carboxy-4-methyl-5-propyl-2- furanpropanoic acid (CMPF).

  • Download the structure of HSA from PDB (
  • You can either download the PDB format as usual or download the PDBx/mmCIF format if you face any problems regarding the loading of the structure.
  • Save this file in a folder.

Downloading ligands

We are going to dock Sodium Octanoate (SO), naphthalene (NAPH), and salicylic acid (SA) with the HSA. If you are going to dock a database then find a link to download the same or some selected compounds from the database. Don’t download them one by one. This tutorial is for demonstration purposes only, therefore, we are docking three ligands only. For more details on downloading small molecules from the ZINC database, read this article. If you have downloaded smiles of ligands, then this article will help you to convert them into 3D structures.

  • Go to Pubchem (
  • Search for the given compounds.
  • Download their 3D conformers in SDF format.
  • You can download the structure from another database as well such as ZINC.

Preparing the protein

To prepare the protein for docking, you need to know the binding site/ binding residues. They can be present in a single chain of a protein or might involve two. Read the associated paper published for that structure. It consists of all the structural details about it. If there is no literature available on the binding site of that protein, then go for the prediction. Read this article for more information.

In the present case, you can also get all binding residues by visualizing the HSA-CMPF complex in Pymol and note down all interacting residues. But always try to find the binding sites in published papers.

Since we already know the binding sites of HSA, we can proceed to prepare our protein.

  • Open the PDB file and remove HETATOMS.
    The structure we are using is a crystal structure complexed with ligand(s), therefore, to dock the desired ligand with the protein in that particular position we need to remove the bound ligand by removing hetatoms from the PDB file. If we will dock our ligand without removing the bound ligand, then we will not get the correct results. We can also easily remove ligands by visualizing the protein in PyMol.
    Read this article to know how to remove hetatoms.
  • Remove extra chains
    We will keep only one of the four chains (here, Chain A was taken) and remove the rest of the three chains. The chains are removed from the protein structure just to avoid complexity. Read this article to know how to remove chains.
  • Save the file
    Now save the file as “protein.pdb”.

We have prepared our protein structure to proceed further for docking. Now let’s prepare our ligands.

Preparing the ligands

Since we need the protein and the ligand in a .pdb format, therefore, we have to convert the ligand from SDF to pdb format. We will use PyMol for this purpose and never use online converters because they may ruin your ligand file. You can also use Openbabel.

  • Open PyMol and open the downloaded ligand.
  • Click on “File” –> “Save Molecule” –> select the molecule –> click “OK”.
  • Save it in the same folder as with the proper name.
  • Repeat for all ligands. This would be tedious if you have hundreds of ligands. For this, use Openbabel software.

Performing docking using Pyrx

We will be using Autodock Vina for docking. It is provided in Pyrx that you can dock using the Vina algorithm. Run Pyrx GUI and follow the steps explained below.

Loading protein and ligand

  • Go to ‘File’ –> ‘Load Molecule’ or just click on the very first icon given in the top left corner.
  • Select the downloaded protein structure. Here, named ‘protein.pdb’.
  • Again go to ‘File’ –> ‘Load Molecule’ or just click on the very first icon given in the top left corner.
  • Select the converted ligand structure.
  • Repeat for all three ligands or select all ligands at once.

Defining protein and ligand

You will see the loaded protein and ligands under the ‘Molecules’ tab. Now we have to define which one is protein and which one is the ligand. To do that

  • Right-click on protein –> ‘Autodock’ –> ‘Make Macromolecule’.
  • Right-click on ligand –> ‘Autodock’ –> ‘Make Ligand’. Repeat this step for all ligands.

After that you will notice under the ‘Autodock’ tab, it has prepared all PDBQT files itself.

Defining grid box

Look at the ‘Controls’ panel given at the bottom under the ‘Select molecule’ tab. You will see “1 ligand selected” and the path of the selected protein. Select all ligands for docking.

  • Now, click the ‘Forward’ button present at the bottom right corner. You will see a grid box on the display screen.
  • Go back to the ‘Molecules’ tab on the right side. Click on the “+” sign of the loaded protein. You will see all the residues present in the chain.
  • Select the binding residues by right-clicking on the residue –> Display –> Label –> Atoms. You will see the atoms appearing on the protein.
  • Now adjust the grid box accordingly such that all the selected residues come inside the box. You don’t have to enclose the ligand inside the grid box.

Running Vina for docking

You can set the exhaustiveness by entering an appropriate number in the box given at the bottom left. After adjusting everything, click on the ‘Forward’ button. It will start docking and will display the processing. After the docking is finished, you will see the poses and their binding affinities in the bottom panel. It will show all nine poses along with other values such as RMSD.

Now to analyze these results, you will have to open the PDB/PDBQT file of the protein and the vina output file in Pymol. For analyzing results, read this article. You can also analyze these results in Discovery Studio Visualizer, read here to analyze docking results in DS Visualizer.



Dr. Muniba is a Bioinformatician based in New Delhi, India. She has completed her PhD in Bioinformatics from South China University of Technology, Guangzhou, China. She has cutting edge knowledge of bioinformatics tools, algorithms, and drug designing. When she is not reading she is found enjoying with the family. Know more about Muniba


What values are considered as good or bad in computational docking?



After performing computational docking, a question that comes to mind most is “what docking score is considered good or bad”. In this article, we will discuss this in detail. (more…)

Continue Reading

Bioinformatics Programming

How to sort binding affinities based on a cutoff using script?



How to sort binding affinities based on a cutoff using script?

Previously, we have provided a Python script ( to analyze the virtual screening (VS) results of Autodock Vina. Now, we have updated this script to sort binding affinities based on user inputted cutoff value. (more…)

Continue Reading


Virtual Screening using Autodock Vina: Frequently Asked Questions & Answers for Starters



Virtual Screening using Autodock Vina: Virtual Screening: Frequently Asked Questions & Answers for Starters

Virtual Screening (VS) is one of the important techniques in bioinformatics. It can be easily performed using Autodock Vina. We have provided detailed articles on this topic. In this article, we are trying to answer some FAQs for beginners. (more…)

Continue Reading