{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Protein dihedral angle analysis\n", "\n", "We look at backbone dihedral angles and generate Ramachandran and Janin plots.\n", "\n", "The methods and examples shown here are only applicable to Universes where protein residue names have standard names, i.e. the backbone is comprised of --N--CA--C--N--CA-- atoms.\n", "\n", "\n", "\n", "**Last updated:** December 2022 with MDAnalysis 2.4.0-dev0\n", "\n", "**Minimum version of MDAnalysis:** 0.19.0\n", "\n", "**Packages required:**\n", " \n", "* MDAnalysis (Michaud-Agrawal *et al.*, 2011, Gowers *et al.*, 2016)\n", "* MDAnalysisTests\n", "\n", "**Optional packages for visualisation:**\n", "\n", "* [matplotlib](https://matplotlib.org)" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "execution": { "iopub.execute_input": "2021-05-19T05:58:07.289111Z", "iopub.status.busy": "2021-05-19T05:58:07.287941Z", "iopub.status.idle": "2021-05-19T05:58:08.065635Z", "shell.execute_reply": "2021-05-19T05:58:08.066015Z" } }, "outputs": [], "source": [ "import MDAnalysis as mda\n", "from MDAnalysis.tests.datafiles import GRO, XTC\n", "from MDAnalysis.analysis import dihedrals\n", "import matplotlib.pyplot as plt\n", "import numpy as np\n", "%matplotlib inline" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Loading files" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "The test files we will be working with here feature adenylate kinase (AdK), a phosophotransferase enzyme. (Beckstein *et al.*, 2009)" ] }, { "cell_type": "code", "execution_count": 2, "metadata": { "execution": { "iopub.execute_input": "2021-05-19T05:58:08.070645Z", "iopub.status.busy": "2021-05-19T05:58:08.069949Z", "iopub.status.idle": "2021-05-19T05:58:08.534249Z", "shell.execute_reply": "2021-05-19T05:58:08.534698Z" } }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "There are 214 residues in the protein\n" ] } ], "source": [ "u = mda.Universe(GRO, XTC)\n", "protein = u.select_atoms('protein')\n", "print('There are {} residues in the protein'.format(len(protein.residues)))" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Selecting dihedral atom groups\n", "\n", "Proteins have canonical dihedral angles defined on the backbone atoms. $\\phi$ (phi), $\\psi$ (psi) and $\\omega$ (omega) are backbone angles. The side-chain dihedral angles are called $\\chi_n$ (chi-$n$), and can vary in number.\n", "\n", "