pdb_annotations: Fetch PDB structural annotations for a UniProt accession

View source: R/utils_pdb.R

pdb_annotationsR Documentation

Fetch PDB structural annotations for a UniProt accession

Description

Queries the PDBe APIs for secondary structure and ligand binding sites from experimental PDB structures, converts residue numbers to UniProt canonical coordinates via SIFTS, and returns named lists of A3Region and A3Site objects ready for use with create_A3().

Usage

pdb_annotations(
  accession,
  pdb_id = NULL,
  pdbe_graph_url = "https://www.ebi.ac.uk/pdbe/graph-api",
  pdbe_api_url = "https://www.ebi.ac.uk/pdbe/api",
  verbosity = 1L
)

Arguments

accession

Character scalar: UniProt accession, e.g. "P10636".

pdb_id

Optional character scalar: Four-character PDB ID (e.g. "2mz7"). If NULL, the top-ranked structure from PDBe is used.

pdbe_graph_url

Character scalar: PDBe Graph API base URL.

pdbe_api_url

Character scalar: PDBe REST API base URL.

verbosity

Integer scalar: Verbosity level.

Details

Structure ranking and SIFTS residue mappings come from the PDBe Graph API best_structures endpoint. Secondary structure and binding sites are fetched from the PDBe REST API.

When pdb_id is NULL the top-ranked structure (by PDBe coverage score) is used automatically.

Value

Named list with two elements:

region

Named list of A3Region objects for secondary structure (types: "helix", "betaStrand", "turn").

site

Named list of A3Site objects for ligand binding sites (type: "bindingSite").

Author(s)

EDG

Examples

# Requires internet connection and fetches data from PDBe.
## Not run: 
  ann  <- pdb_annotations("P10636")
  mapt <- create_A3(
    sequence = uniprot_sequence("P10636"),
    region   = ann[["region"]],
    site     = ann[["site"]]
  )

## End(Not run)

rtemis.a3 documentation built on April 29, 2026, 1:06 a.m.