Skip to content

Commit

Permalink
fixed docs for PDBParser "conect" keyword (#1329)
Browse files Browse the repository at this point in the history
- fixes #1246
- supercedes and closes PR #1279 by @Shtkddud123
- added @Shtkddud123 to AUTHORS
- updated CHANGELOG
  • Loading branch information
Shtkddud123 authored and kain88-de committed May 2, 2017
1 parent ac27e28 commit c1e751e
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 14 deletions.
1 change: 1 addition & 0 deletions package/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ Chronological list of authors
- Akshay Gupta
- Juan Eiros Zamora
- Jon Kapla
- Sang Young Noh

External code
-------------
Expand Down
3 changes: 2 additions & 1 deletion package/CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The rules for this file:
------------------------------------------------------------------------------

mm/dd/17 utkbansal, kain88-de, xiki-tempula, kaplajon, wouterboomsma,
richardjgowers
richardjgowers, Shtkddud123

* 0.16.1

Expand All @@ -36,6 +36,7 @@ Fixes
module.
* Fix hbond_analysis cannot deal with Universe where no two atoms are with 3A.
(PR #1325)
* Fix PDBParser docs for conect (issue #1246)

Changes
* Enable various pylint warnings to increase python 3 compatibility
Expand Down
32 changes: 19 additions & 13 deletions package/MDAnalysis/coordinates/PDB.py
Original file line number Diff line number Diff line change
Expand Up @@ -505,31 +505,32 @@ def __init__(self, filename, bonds="conect", n_atoms=None, start=0, step=1,
convert_units=None, multiframe=None):
"""Create a new PDBWriter
:Arguments:
*filename*
Parameters
----------
filename: str
name of output file
*start*
start: int (optional)
starting timestep
*step*
step: int (optional)
skip between subsequent timesteps
*remarks*
comments to annotate pdb file (added to the TITLE record); note that
remarks: str (optional)
comments to annotate pdb file (added to the *TITLE* record); note that
any remarks from the trajectory that serves as input are
written to REMARK records with lines longer than :attr:`remark_max_length` (66
characters) being wrapped.
*convert_units*
convert_units: str (optional)
units are converted to the MDAnalysis base format; ``None`` selects
the value of :data:`MDAnalysis.core.flags` ['convert_lengths']
*bonds*
write bonds to the PDB file as CONECT_ records [``False``]
*multiframe*
bonds : {"conect", "all", None} (optional)
If set to "conect", then only write those bonds that were already
defined in an input PDB file as PDB CONECT_ record. If set to "all",
write all bonds (including guessed ones) to the file. ``None`` does
not write any bonds. The default is "conect".
multiframe: bool (optional)
``False``: write a single frame to the file; ``True``: create a
multi frame PDB file in which frames are written as MODEL_ ... ENDMDL_
records. If ``None``, then the class default is chosen. [``None``]
.. _CONECT: http://www.wwpdb.org/documentation/format32/sect10.html#CONECT
.. _MODEL: http://www.wwpdb.org/documentation/format32/sect9.html#MODEL
.. _ENDMDL: http://www.wwpdb.org/documentation/format32/sect9.html#ENDMDL
Note
----
Expand All @@ -540,6 +541,11 @@ def __init__(self, filename, bonds="conect", n_atoms=None, start=0, step=1,
atoms in the new PDB file and therefore a :exc:`NotImplementedError` is
raised.)
.. _CONECT: http://www.wwpdb.org/documentation/format32/sect10.html#CONECT
.. _MODEL: http://www.wwpdb.org/documentation/format32/sect9.html#MODEL
.. _ENDMDL: http://www.wwpdb.org/documentation/format32/sect9.html#ENDMDL
"""
# n_atoms = None : dummy keyword argument
# (not used, but Writer() always provides n_atoms as the second argument)
Expand Down

0 comments on commit c1e751e

Please sign in to comment.