UniprotGrouping#

class biotite.database.rcsb.UniprotGrouping(sort_by=None)[source]#

Bases: Grouping

This class groups protein chains that point to the same Uniprot accession ID.

This Grouping is only applicable, if the count()/search() return type is set to polymer_entity.

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() and count() 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 API return_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.