This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Example to align two equivalent protein structures. | |
""" | |
from Bio.PDB import PDBParser, Superimposer | |
parser = PDBParser(QUIET=1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Replaces the bfactor column of a PDB file | |
with the charge information present in a | |
CNS topology file. | |
Atoms missing from the topology are automatically | |
assigned a set charge (default 0.0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
if len(sys.argv[1:]) != 1: | |
print "usage: sort_pdb.py <pdb file>" | |
sys.exit(1) | |
try: | |
with open(sys.argv[1]) as handle: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from Bio.PDB import PDBParser, PDBIO, | |
class PREFilter(Select): | |
def accept_atom(self, atom): | |
forbidden_atoms = set(['N', 'C', '...']) | |
if atom.parent.resname == 'CYS' and atom.name in forbidden_atoms: | |
if atom - atom.parent['CA'] > 3.0: | |
continue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -* | |
""" | |
Utility script to analyze several docking poses of a protein complex. | |
Produces PDB file with color-coded ligand center-of-mass positions | |
that reflect the population density (i.e. number of neighbor models). | |
Works with multiple chain models by considering as "ligand" all chains | |
defined as NOT part of the receptor. Default, chain A is the only receptor. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Analyzes the RMSD on a residue basis for an ensemble | |
of protein structures. | |
""" | |
from __future__ import print_function, division | |
import argparse |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Utility to match (and compare) PDB files. | |
On homo-multimers, will match chains sequentially. | |
Uses global sequence alignment to find equivalent positions | |
between the sequences. Also superimposes the structures based | |
on the alignments and outputs per-chain RMSDs. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from __future__ import print_function, division | |
from operator import itemgetter | |
import os | |
import sys | |
import tempfile | |
import warnings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
"""Sequence-based structural alignment of two proteins.""" | |
import argparse | |
import pathlib | |
from Bio.PDB import FastMMCIFParser, MMCIFIO, PDBParser, PDBIO, Superimposer | |
from Bio.PDB.Polypeptide import is_aa |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Smooths a trajectory using mdtraj and an weighted adaptive window algorithm. | |
""" | |
from __future__ import print_function, division | |
import argparse | |
import os |
OlderNewer