Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
openstructure
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
schwede
openstructure
Commits
fd54b151
Commit
fd54b151
authored
6 years ago
by
Xavier Robin
Browse files
Options
Downloads
Patches
Plain Diff
Write doc for EntityToPDBStr and PDBStrToEntity.
parent
c5331bdb
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/io/doc/io.rst
+34
-0
34 additions, 0 deletions
modules/io/doc/io.rst
with
34 additions
and
0 deletions
modules/io/doc/io.rst
+
34
−
0
View file @
fd54b151
...
...
@@ -70,6 +70,31 @@ behaviour.
.. autofunction:: ost.io.LoadPDB
.. function:: PDBStrToEntity(pdb_string, profile=IOProfile(), process=False)
Load entity from a string in PDB format. By default the entity is loaded with
an empty IO Profile and is not processed with the :class:`~ost.conop.Processor`,
even if one is available in the IO Profile.
:param pdb_string: A PDB file as a string.
:param profile: The IO Profile to read the entity with. For more information
on the IO Profiles available, see :doc:`profile`.
:param process: If set to True, run the :class:`~ost.conop.Processor`
contained in the IO Profile.
:rtype: :class:`~ost.mol.EntityHandle`.
To get an entity equivalent to one loaded with :func:`LoadPDB`, set the
`profile` and `process` arguments as follows:
.. code-block:: python
with open('protein.pdb') as pdb_fd:
pdb_str = pdb.read()
ent = io.PDBStrToEntity(pdb_str, ost.io.profiles['DEFAULT'], True)
Saving Molecular Structures
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...
...
@@ -117,7 +142,16 @@ file:
.. autofunction:: ost.io.SavePDB
.. function:: EntityToPDBStr(ent, profile=IOProfile())
Return entity as a string in PDB format.
:param entity: The :class:`~ost.mol.EntityHandle` or :class:`~ost.mol.EntityView`
:param profile: The IO Profile to read the entity with. For more information
on the IO Profiles available, see :doc:`profile`.
:rtype: string.
.. _seq-io:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment