Skip to main content
Warning: You are using the test version of PyPI. This is a pre-production deployment of Warehouse. Changes made here affect the production instance of TestPyPI (testpypi.python.org).
Help us improve Python packaging - Donate today!

Calculate RMSD using, translation and rotation, between molecules

Project Description

The root-mean-square deviation (RMSD) is calculated, using Kabsch algorithm (1976) or Quaternion algorithm (1991) for rotation, between two Cartesian coordinates in either .xyz or .pdb format, resulting in the minimal RMSD.

For more information please read RMSD and Kabsch algorithm.

Installation

From PyPI

pip install rmsd

Download Python file

There is only one Python file, so you can also download that and put it in your bin folder.

wget -O calculate_rmsd https://raw.githubusercontent.com/charnley/rmsd/master/calculate_rmsd.py

If you want to use it as a python package, then clone it the down and copy-paste the rmsd folder to the directory you need.

Usage

Type calculate_rmsd --help for all the arguments.

Pretty straight forward execution, clone and run as

calculate_rmsd molecule1.xyz molecule2.xyz

or

calculate_rmsd protein.pdb protein.pdb

Citation

  • Kabsch algorithm:
    Kabsch W., 1976, A solution for the best rotation to relate two sets of vectors, Acta Crystallographica, A32:922-923, doi: http://dx.doi.org/10.1107/S0567739476001873
  • Quaternion algorithm:
    Michael W. Walker and Lejun Shao and Richard A. Volz, 1991, Estimating 3-D location parameters using dual number quaternions, CVGIP: Image Understanding, 54:358-367, doi: http://dx.doi.org/10.1016/1049-9660(91)90036-o
  • Implementation:
    Calculate RMSD for two XYZ structures, GitHub, http://github.com/charnley/rmsd, <commit hash or version number>

Please remmeber to cite this implementation when using it for scientific publications.

More usage examples

Same structure, but translated in space, so the RMSD should be zero

calculate_rmsd examples/ethane.xyz examples/ethane_translate.xyz

You can also output (stdout) molecule1’s coordinates centered and rotated to molecule2. Useful to visualize the difference. The output will be in XYZ format.

calculate_rmsd --output examples/ethane.xyz examples/ethane_translate.xyz

You can also use PDB format by using the argument -f pdb as seen:

calculate_rmsd -f pdb examples/ci2_1.pdb examples/ci2_2.pdb

Problems?

Submit issues on GitHub or submit pull requests.

Release History

Release History

This version
History Node

1.2.2

History Node

1.2.1

History Node

1.2.0

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
rmsd-1.2.2.tar.gz (7.4 kB) Copy SHA256 Checksum SHA256 Source May 15, 2017

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting