Merge pull request #61 from Electrostatics/nathan/v3.2
Merge changes needed to release v3.2
This commit is contained in:
11
INSTALL
11
INSTALL
@@ -1,11 +0,0 @@
|
||||
## Installation
|
||||
|
||||
Clone repository or unpack the tar ball and install with
|
||||
[pip](https://pip.pypa.io):
|
||||
|
||||
pip install propka-3.1/
|
||||
|
||||
This will install the `propka31` script in your executable
|
||||
directory. The `propka` Python module will also become available for
|
||||
import.
|
||||
|
||||
89
README.md
89
README.md
@@ -1,10 +1,10 @@
|
||||
# PROPKA 3.1
|
||||
# PROPKA 3
|
||||
|
||||
PROPKA predicts the pKa values of ionizable groups in proteins
|
||||
(version 3.0) and protein-ligand complexes (version 3.1)
|
||||
(version 3.0) and protein-ligand complexes (version 3.1 and later)
|
||||
based on the 3D structure.
|
||||
|
||||
For proteins without ligands both version should produce the same result.
|
||||
For proteins without ligands, both version should produce the same result.
|
||||
|
||||
The method is described in the following papers, which you should cite
|
||||
in publications:
|
||||
@@ -13,58 +13,68 @@ in publications:
|
||||
|
||||
* Olsson, Mats HM, Chresten R. Sondergaard, Michal Rostkowski, and Jan H. Jensen. "PROPKA3: consistent treatment of internal and surface residues in empirical pKa predictions." Journal of Chemical Theory and Computation 7, no. 2 (2011): 525-537. doi:[10.1021/ct100578z](https://doi.org/10.1021/ct100578z)
|
||||
|
||||
See [propka.ki.ku.dk](http://propka.ki.ku.dk/) for the PROPKA web server,
|
||||
using the [tutorial](http://propka.ki.ku.dk/~luca/wiki/index.php/PROPKA_3.1_Tutorial).
|
||||
## PROPKA versions
|
||||
|
||||
|
||||
## Installation
|
||||
|
||||
Clone repository or unpack the tar ball and install with
|
||||
[setuptools](http://pythonhosted.org/setuptools/index.html) (note: if
|
||||
you don't have setuptools installed you will need an internet
|
||||
connection so that the installation procedure can download the
|
||||
required files):
|
||||
|
||||
cd propka-3.1
|
||||
python setup.py install --user
|
||||
|
||||
This will install the `propka31` script in your executable directory,
|
||||
as configured for setuptools, for instance `~/.local/bin`. You can
|
||||
change the bin directory with the `--install-scripts` option. For
|
||||
example, in order to install in my `bin` directory in my home
|
||||
directory:
|
||||
|
||||
python setup.py install --user --install-scripts ~/bin
|
||||
|
||||
For the purposes of testing or development, you may prefer to install PROPKA as
|
||||
an editable module via PIP by running
|
||||
```
|
||||
pip install -e .
|
||||
```
|
||||
from within a virtual environment (e.g., via [virtualenv](https://pypi.org/project/virtualenv/)).
|
||||
The code in this repository is named _PROPKA 3_ and it is based on the original PROPKA 3.1 release (described in the papers above). It has undergone various changes, which is reflected in the version numbering. For instance, version 3.2 contains a number of API changes and code refactoring that introduce incompatibilities between the original 3.1 release and the more recent versions. In the future, we will increase the minor version number to indicate further changes to the code base (e.g., release 3.3 or 3.4). The major release number is not expected to change unless major changes to the underlying algorithms are implemented.
|
||||
|
||||
## Requirements
|
||||
|
||||
* Python 3.5 or higher
|
||||
PROPKA 3 requires Python 3.6 or higher. Additional requirements are specified in the `requirements.txt` file and automatically satisfied when installing with [pip](https://pip.pypa.io).
|
||||
|
||||
## Installation
|
||||
|
||||
### PIP-based installation
|
||||
|
||||
The easiest way to install PROPKA is via the [PyPI archive](https://pypi.org/project/PROPKA/) with the command
|
||||
|
||||
pip install propka
|
||||
|
||||
This installation will install the `propka` Python module and the `propka3` executable script.
|
||||
As always, a virtual environment (e.g., via [virtualenv](https://pypi.org/project/virtualenv/)) is recommended when installing packages.
|
||||
|
||||
### Source-based installation
|
||||
|
||||
The source code can be installed by cloning the repository or unpacking from a source code archive and running
|
||||
|
||||
pip install .
|
||||
|
||||
in the source directory.
|
||||
For the purposes of testing or development, you may prefer to install PROPKA as an editable module via PIP by running
|
||||
|
||||
pip install -e .
|
||||
|
||||
in the source directory.
|
||||
|
||||
## Getting started
|
||||
|
||||
1. Clone the code from GitHub
|
||||
2. `python setup.py install --user`
|
||||
2. Run `propka31` with a .pdb file (see Examples)
|
||||
PROPKA can be used either as a module or via the installed script; i.e., either
|
||||
|
||||
## Examples
|
||||
propka3
|
||||
|
||||
Calculate using pdb file
|
||||
or
|
||||
|
||||
propka31 1hpx.pdb
|
||||
python -m propka
|
||||
|
||||
works for invoking PROPKA.
|
||||
|
||||
A brief list of available options can be obtained by running PROPKA with no options:
|
||||
|
||||
propka3
|
||||
|
||||
A longer list of options and descriptions is available using the `--help` option:
|
||||
|
||||
propka3 --help
|
||||
|
||||
Most users run PROPKA by invoking the program with a PDB file as its argument; e.g.,
|
||||
|
||||
propka3 1hpx.pdb
|
||||
|
||||
## Testing (for developers)
|
||||
|
||||
Please see [`tests/README.md`](tests/README.md) for testing instructions.
|
||||
Please run these tests after making changes to the code and _before_ pushing commits.
|
||||
|
||||
|
||||
## References / Citations
|
||||
|
||||
Please cite these references in publications:
|
||||
@@ -72,6 +82,3 @@ Please cite these references in publications:
|
||||
* Sondergaard, Chresten R., Mats HM Olsson, Michal Rostkowski, and Jan H. Jensen. "Improved Treatment of Ligands and Coupling Effects in Empirical Calculation and Rationalization of pKa Values." Journal of Chemical Theory and Computation 7, no. 7 (2011): 2284-2295.
|
||||
|
||||
* Olsson, Mats HM, Chresten R. Sondergaard, Michal Rostkowski, and Jan H. Jensen. "PROPKA3: consistent treatment of internal and surface residues in empirical pKa predictions." Journal of Chemical Theory and Computation 7, no. 2 (2011): 525-537.
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
"""PROPKA 3.1
|
||||
"""PROPKA 3
|
||||
|
||||
See https://github.com/jensengroup/propka-3.1 for more information.
|
||||
|
||||
|
||||
@@ -363,7 +363,7 @@ def get_propka_header():
|
||||
string
|
||||
"""
|
||||
today = date.today()
|
||||
str_ = "propka3.1 {0!s:>93s}\n".format(today)
|
||||
str_ = "propka3.2 {0!s:>93s}\n".format(today)
|
||||
str_ += """
|
||||
-------------------------------------------------------------------------------
|
||||
-- --
|
||||
@@ -381,6 +381,9 @@ def get_propka_header():
|
||||
-- VERSION 3.1, 07/01/2011, COPENHAGEN --
|
||||
-- BY CHRESTEN R. SONDERGARD AND MATS H.M. OLSSON --
|
||||
-- --
|
||||
-- VERSION 3.2, 06/17/2020, PLANET EARTH --
|
||||
-- SEE ABOVE FOR AUTHORS --
|
||||
-- --
|
||||
-------------------------------------------------------------------------------
|
||||
"""
|
||||
return str_
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
#!/usr/bin/env python
|
||||
"""PROPKA script.
|
||||
|
||||
This is the original propka script. However, this distribute-based
|
||||
installation moved the main() function into propka.run.main and just
|
||||
generates a script called propka31 from the setup.py installation
|
||||
script. You should not need to use this script.
|
||||
|
||||
(Also note that there can be import problems because the script name
|
||||
is the same as the module name; that's why the new script is called
|
||||
propka31.)
|
||||
"""
|
||||
from propka.lib import loadOptions
|
||||
from propka.input import read_parameter_file, read_molecule_file
|
||||
from propka.parameters import Parameters
|
||||
from propka.molecular_container import MolecularContainer
|
||||
|
||||
|
||||
def main():
|
||||
"""Read in structure files, calculates pKa values, and prints pKa files."""
|
||||
# loading options, flaggs and arguments
|
||||
options = loadOptions([])
|
||||
pdbfiles = options.filenames
|
||||
parameters = read_parameter_file(options.parameters, Parameters())
|
||||
|
||||
for pdbfile in pdbfiles:
|
||||
my_molecule = MolecularContainer(parameters, options)
|
||||
my_molecule = read_molecule_file(pdbfile, my_molecule)
|
||||
my_molecule.calculate_pka()
|
||||
my_molecule.write_pka()
|
||||
if options.generate_propka_input:
|
||||
my_molecule.write_propka()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
37
setup.py
37
setup.py
@@ -1,19 +1,16 @@
|
||||
#! /usr/bin/python
|
||||
# PROPKA 3.1
|
||||
#
|
||||
#
|
||||
# setuptools installation of PROPKA 3.1
|
||||
# PROPKA 3
|
||||
|
||||
from setuptools import setup, find_packages
|
||||
|
||||
VERSION = "3.1.1"
|
||||
VERSION = "3.2.0"
|
||||
|
||||
setup(name="PROPKA",
|
||||
setup(
|
||||
name="propka",
|
||||
version=VERSION,
|
||||
description="Heuristic pKa calculations with ligands",
|
||||
long_description="""
|
||||
description="Heuristic pKa calculations with ligands", long_description="""
|
||||
PROPKA predicts the pKa values of ionizable groups in proteins (version 3.0) and
|
||||
protein-ligand complexes (version 3.1) based on the 3D structure.
|
||||
protein-ligand complexes (version 3.1 and later) based on the 3D structure.
|
||||
|
||||
For proteins without ligands both version should produce the same result.
|
||||
|
||||
@@ -34,6 +31,8 @@ See http://propka.org/ for the PROPKA web server.
|
||||
""",
|
||||
author="Jan H. Jensen",
|
||||
author_email="jhjensen@chem.ku.dk",
|
||||
maintainer="Nathan Baker",
|
||||
maintainer_email="nathanandrewbaker@gmail.com",
|
||||
license="LGPL v2.1",
|
||||
url="http://propka.org",
|
||||
keywords="science",
|
||||
@@ -43,20 +42,20 @@ See http://propka.org/ for the PROPKA web server.
|
||||
'Intended Audience :: Science/Research',
|
||||
'License :: OSI Approved :: GNU Lesser General Public License v2 (LGPLv2)',
|
||||
'Operating System :: POSIX',
|
||||
'Operating System :: MacOS :: MacOS X',
|
||||
'Operating System :: Microsoft :: Windows',
|
||||
'Programming Language :: Python',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
'Topic :: Scientific/Engineering :: Bio-Informatics',
|
||||
'Topic :: Scientific/Engineering :: Chemistry',
|
||||
],
|
||||
packages=find_packages(exclude=['scripts']),
|
||||
package_data = {'propka': ['*.dat', '*.cfg']},
|
||||
#scripts = ["scripts/propka31.py"], # use entry point below
|
||||
entry_points = {
|
||||
'console_scripts': [
|
||||
'propka31 = propka.run:main',
|
||||
],
|
||||
},
|
||||
package_data={'propka': ['*.dat', '*.cfg', '*.json']},
|
||||
entry_points={'console_scripts': ['propka3 = propka.run:main', ]},
|
||||
zip_safe=True,
|
||||
python_requires='>=3.5',
|
||||
tests_require=["pandas", "numpy"],
|
||||
python_requires='>=3.6',
|
||||
tests_require=["pandas", "numpy", "pytest"],
|
||||
test_suite="tests",
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
"""Tests for PROPKA 3.1"""
|
||||
"""Tests for PROPKA"""
|
||||
import logging
|
||||
import os
|
||||
import re
|
||||
|
||||
Reference in New Issue
Block a user