Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/BDB-Genomics/AlphaGenomeR/llms.txt

Use this file to discover all available pages before exploring further.

Two extractor functions handle ChIP-seq modalities: alphagenome_get_chip_tf() for transcription factor binding predictions and alphagenome_get_chip_histone() for histone modification predictions. Both access their respective slots from the Python response object returned by alphagenome_query() and convert the data to native R structures. Either function returns NULL if the corresponding modality was not included in requested_outputs.

alphagenome_get_chip_tf()

Transcription factor ChIP-seq (TF ChIP-seq) measures genome-wide binding of specific transcription factors to chromatin. alphagenome_get_chip_tf() extracts the chip_tf slot from the AlphaGenome response via reticulate::py_get_attr().

Function signature

alphagenome_get_chip_tf(response_body)

Parameters

response_body
list
required
The list returned by alphagenome_query(). Must have been called with "CHIP_TF" in requested_outputs.

Return value

result
list or NULL
Returns NULL if "CHIP_TF" was not in requested_outputs. Otherwise returns a named list:

Example

library(AlphaGenomeR)

api_key <- Sys.getenv("ALPHAGENOME_API_KEY")

results <- alphagenome_query(
  access_token      = api_key,
  genomic_region    = "chr17:42560601-43609177",
  ontology_terms    = c("UBERON:0002048"),
  requested_outputs = c("CHIP_TF")
)

chip_tf_data <- alphagenome_get_chip_tf(results)

dim(chip_tf_data$values)    # positions x tracks
head(chip_tf_data$metadata) # includes TF names and tissue annotations

alphagenome_get_chip_histone()

Histone ChIP-seq measures genome-wide enrichment of histone modifications (e.g., H3K4me3, H3K27ac) that mark active promoters, enhancers, and other regulatory elements. alphagenome_get_chip_histone() extracts the chip_histone slot from the AlphaGenome response.

Function signature

alphagenome_get_chip_histone(response_body)

Parameters

response_body
list
required
The list returned by alphagenome_query(). Must have been called with "CHIP_HISTONE" in requested_outputs.

Return value

result
list or NULL
Returns NULL if "CHIP_HISTONE" was not in requested_outputs. Otherwise returns a named list:

Example

library(AlphaGenomeR)

api_key <- Sys.getenv("ALPHAGENOME_API_KEY")

results <- alphagenome_query(
  access_token      = api_key,
  genomic_region    = "chr17:42560601-43609177",
  ontology_terms    = c("UBERON:0002048"),
  requested_outputs = c("CHIP_HISTONE")
)

chip_histone_data <- alphagenome_get_chip_histone(results)

dim(chip_histone_data$values)    # positions x tracks
head(chip_histone_data$metadata) # includes histone mark names and tissue annotations
You can request both TF and histone ChIP-seq in a single query: requested_outputs = c("CHIP_TF", "CHIP_HISTONE"). Each extractor operates independently on its own slot in the response.

Build docs developers (and LLMs) love