Skip to content

Commit

Permalink
1.0.0 docs
Browse files Browse the repository at this point in the history
  • Loading branch information
samirelanduk committed Jun 23, 2019
1 parent 1780de1 commit 0b4626b
Show file tree
Hide file tree
Showing 6 changed files with 97 additions and 7 deletions.
2 changes: 1 addition & 1 deletion LICENSE
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2018 Sam Ireland
Copyright (c) 2019 Sam Ireland

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
50 changes: 47 additions & 3 deletions README.rst
Expand Up @@ -74,6 +74,31 @@ fetching structures over SSH,
and `valerius <https://valerius.samireland.com>`_ for dealing with sequences.


Testing
~~~~~~~

To test a local version of atomium, cd to the atomium directory and run:

``$ python -m unittest discover tests``

You can opt to only run unit tests or integration tests:

``$ python -m unittest discover tests.unit``
``$ python -m unittest discover tests.integration``

You can run the 'big test' to get a random 1000 structures, parse them all, and
report any problems:

``$ python tests/big.py``

Finally, to perform speed profiles you can run:

``$ python tests/time/time.py``

...which creates various profiles that SnakeViz can visualise.



Overview
--------

Expand Down Expand Up @@ -112,7 +137,7 @@ Once you've got your ``File`` object, what can you do with it?
Annotation
##########

There is various meta information contained within the ``File`` object.
There is meta information contained within the ``File`` object:

>>> pdb1.title
'CRYSTAL STRUCTURE OF OROTIDINE MONOPHOSPHATE DECARBOXYLASE COMPLEX WITH XMP'
Expand Down Expand Up @@ -177,8 +202,6 @@ the asymmetric unit with 1,842 atoms, and then generate two of its possible
biological assemblies by passing in their IDs.




Model Contents
##############

Expand All @@ -203,6 +226,8 @@ The basic structures within a model are chains, residues, ligands, and atoms.
037)>, <Residue PRO (A.129)>, <Residue PRO (B.1161)>, <Residue TYR (A.206)>}
>>> pdb1.model.chain('B').residue('B.1206')
<Residue TYR (B.1206)>
>>> pdb1.model.chain('B').residue('B.1206').helix
True
>>> pdb1.model.ligands()
{<Ligand BU2 (A.5001)>, <Ligand XMP (A.2001)>, <Ligand BU2 (B.5002)>, <Ligan
d XMP (B.2002)>}
Expand Down Expand Up @@ -346,6 +371,25 @@ results.
Changelog
---------

Release 1.0.0
~~~~~~~~~~~~~

`23 June 2019`

* Saving now issues warning if the stucture has duplicate IDs.
* Missing residues parsed for all three file types.
* Crystallographic information now parsed.
* Refactor of atomic structures.
* Refactor of .mmtf parsing.
* Structure copying now retains all properties.
* Fixed bug in parsing .cif expression systems.
* Full names of ligands and modified residues now parsed.
* Secondary structure information parsed and available now.
* Atoms now have covalent radius property for calculating bond cutoffs.
* .pdb parsing can now handle heavy water (DOD).
* General speed improvements.


Release 0.12.2
~~~~~~~~~~~~~~

Expand Down
2 changes: 2 additions & 0 deletions atomium/utilities.py
Expand Up @@ -13,6 +13,7 @@ def open(path, *args, **kwargs):
it accordingly.
For example:
>>> atomium.open('/path/to/file.pdb', data_dict=True)
This will parse file.pdb as a .pdb file, but only go as far as converting it
Expand All @@ -39,6 +40,7 @@ def fetch(code, *args, **kwargs):
look in that location.
For example:
>>> atomium.fetch('1lol.mmtf', file_dict=True)
This will get the .mmtf version of structure 1LOL, but only go as far as
Expand Down
19 changes: 19 additions & 0 deletions docs/source/changelog.rst
@@ -1,6 +1,25 @@
Changelog
---------

Release 1.0.0
~~~~~~~~~~~~~

`23 June 2019`

* Saving now issues warning if the stucture has duplicate IDs.
* Missing residues parsed for all three file types.
* Crystallographic information now parsed.
* Refactor of atomic structures.
* Refactor of .mmtf parsing.
* Structure copying now retains all properties.
* Fixed bug in parsing .cif expression systems.
* Full names of ligands and modified residues now parsed.
* Secondary structure information parsed and available now.
* Atoms now have covalent radius property for calculating bond cutoffs.
* .pdb parsing can now handle heavy water (DOD).
* General speed improvements.


Release 0.12.2
~~~~~~~~~~~~~~

Expand Down
25 changes: 25 additions & 0 deletions docs/source/installing.rst
Expand Up @@ -33,3 +33,28 @@ structures from the RCSB, `paramiko <http://www.paramiko.org//>`_ for
fetching structures over SSH,
`msgpack <https://github.com/msgpack/msgpack-python>`_ for parsing .mmtf files,
and `valerius <https://valerius.samireland.com>`_ for dealing with sequences.


Testing
~~~~~~~

To test a local version of atomium, cd to the atomium directory and run:

``$ python -m unittest discover tests``

You can opt to only run unit tests or integration tests:

``$ python -m unittest discover tests.unit``
``$ python -m unittest discover tests.integration``

You can run the 'big test' to get a random 1000 structures, parse them all, and
report any problems:

``$ python tests/big.py``

Finally, to perform speed profiles you can run:

``$ python tests/time/time.py``

...which creates various profiles that SnakeViz can visualise.

6 changes: 3 additions & 3 deletions docs/source/overview.rst
Expand Up @@ -36,7 +36,7 @@ Once you've got your :py:class:`.File` object, what can you do with it?
Annotation
##########

There is various meta information contained within the :py:class:`.File` object.
There is meta information contained within the :py:class:`.File` object:

>>> pdb1.title
'CRYSTAL STRUCTURE OF OROTIDINE MONOPHOSPHATE DECARBOXYLASE COMPLEX WITH XMP'
Expand Down Expand Up @@ -101,8 +101,6 @@ the asymmetric unit with 1,842 atoms, and then generate two of its possible
biological assemblies by passing in their IDs.




Model Contents
##############

Expand All @@ -127,6 +125,8 @@ The basic structures within a model are chains, residues, ligands, and atoms.
037)>, <Residue PRO (A.129)>, <Residue PRO (B.1161)>, <Residue TYR (A.206)>}
>>> pdb1.model.chain('B').residue('B.1206')
<Residue TYR (B.1206)>
>>> pdb1.model.chain('B').residue('B.1206').helix
True
>>> pdb1.model.ligands()
{<Ligand BU2 (A.5001)>, <Ligand XMP (A.2001)>, <Ligand BU2 (B.5002)>, <Ligan
d XMP (B.2002)>}
Expand Down

0 comments on commit 0b4626b

Please sign in to comment.