DepositGrouping
#
- class biotite.database.rcsb.DepositGrouping(sort_by=None)[source]#
Bases:
Grouping
This class groups PDB entries if they were deposited as a collection. Such a group usually contain the same protein with e.g. a different bound molecule.
This
Grouping
is only applicable, if thecount()
/search()
return type is set toentry
.- Parameters:
- sort_bystr or Sorting, optional
If specified, the returned PDB IDs within each group are sorted by the values of the given field name. A complete list of the available fields is documented at https://search.rcsb.org/structure-search-attributes.html. and https://search.rcsb.org/chemical-search-attributes.html. If a string is given, sorting is performed in descending order. To choose the order a
Sorting
object needs to be provided.
- get_content()#
Get the grouping content, i.e. the data belonging to the
'group_by'
attribute in the RCSB search API.This content is converted into JSON by the
search()
andcount()
functions.ABSTRACT: Override when inheriting.
- Returns:
- contentdict
The content dictionary for the
'group_by'
attributes.
- is_compatible_return_type(return_type)#
Check whether this
Group
is compatible with the RCSB search APIreturn_type
.ABSTRACT: Override when inheriting.
- Parameters:
- return_typestr
The
return_type
attribute to be checked.
- Returns:
- is_compatiblebool
True, if this
Group
is compatible with the return_type, false otherwise.