generate_json_query {rPDBapi}R Documentation

Generate a JSON Query for RCSB PDB Data Retrieval

Description

This function constructs a JSON query for retrieving data from the RCSB Protein Data Bank (PDB). It requires input parameters like IDs, data type, and properties to tailor the query for specific data retrieval needs.

Usage

generate_json_query(ids, data_type, properties)

Arguments

ids

A vector of identifiers for which data needs to be retrieved.

data_type

A string indicating the type of data to be queried, such as 'ENTRY', 'POLYMER_ENTITY', etc.

properties

A list of properties to be included in the query. Each element of the list should be a character vector representing properties for the respective data type.

Value

A string representing the generated JSON query formatted for PDB data retrieval.

Examples

ids <- c("1XYZ", "2XYZ")
properties <- list(cell = c("volume", "angle_beta"), exptl = c("method"))
json_query <- generate_json_query(ids, "ENTRY", properties)
json_query

[Package rPDBapi version 1.3 Index]