bedbaser exposes the bedhost API
and includes convenience functions for common tasks, such as to import a
BED file by id into a GRanges object and a BEDset by its id into a
GRangesList.
BEDbase(cache_path, quietly = FALSE)
getCache(x, cache_type = c("bedfiles", "bedsets"))
setCache(x, cache_path, quietly = TRUE)BEDbase object
BEDbase() creates a cache similar to that of the
Geniml BBClient's cache.
The convenience functions are as follows
bedbaser::BEDbase(): API service constructor
bedbaser::getCache(): Retrieve cache
bedbaser::setCache(): Set path to cache
bedbaser::bb_stats(): Retrieve BEDbase statistics
bedbaser::bb_example(): Retrieve an example BED file or BEDset
bedbaser::bb_metadata(): Retrieve metadata for a BED file or BEDset
bedbaser::bb_list_beds(): List all BED files
bedbaser::bb_list_bedsets(): List all BEDsets
bedbaser::bb_beds_in_bedset(): List BED files in BEDset
bedbaser::bb_bed_text_search(): Search BED files by text
bedbaser::bb_to_granges(): Create a GRanges object from a BED id
bedbaser::bb_to_grangeslist(): Create a GRangesList from a BEDset id
bedbaser::bb_save(): Save a BED file to a path.
bedbase <- BEDbase(cache_path = tempdir())
#> 663721 BED files available.
ex_bed <- bb_example(bedbase, "bed")
bb_metadata(bedbase, ex_bed$id)
#> $name
#> [1] "ENCFF370XZK"
#>
#> $genome_alias
#> [1] "hg38"
#>
#> $genome_digest
#> [1] "Ba88PY52_qeifhJrgUXyin6UITdXNsg3"
#>
#> $bed_compliance
#> [1] "bed5+1"
#>
#> $data_format
#> [1] "bed_like_rs"
#>
#> $compliant_columns
#> [1] 5
#>
#> $non_compliant_columns
#> [1] 1
#>
#> $header
#> NULL
#>
#> $id
#> [1] "0000143becc12fcd50c62f3d78fe7421"
#>
#> $description
#> [1] "female adult (53 years)"
#>
#> $submission_date
#> [1] "2026-04-09T19:40:03.413783Z"
#>
#> $last_update_date
#> [1] "2026-04-14T18:46:25.972343Z"
#>
#> $is_universe
#> [1] FALSE
#>
#> $license_id
#> [1] "DUO:0000042"
#>
#> $annotation
#> $annotation$species_name
#> [1] "Homo sapiens"
#>
#> $annotation$species_id
#> [1] "9606"
#>
#> $annotation$genotype
#> [1] ""
#>
#> $annotation$phenotype
#> [1] ""
#>
#> $annotation$description
#> [1] ""
#>
#> $annotation$cell_type
#> [1] "adrenal gland"
#>
#> $annotation$cell_line
#> NULL
#>
#> $annotation$tissue
#> [1] "endocrine gland, adrenal gland"
#>
#> $annotation$library_source
#> NULL
#>
#> $annotation$assay
#> [1] "PRO-cap"
#>
#> $annotation$antibody
#> NULL
#>
#> $annotation$target
#> NULL
#>
#> $annotation$treatment
#> NULL
#>
#> $annotation$global_sample_id
#> $annotation$global_sample_id[[1]]
#> [1] "encode:ENCFF370XZK"
#>
#>
#> $annotation$global_experiment_id
#> $annotation$global_experiment_id[[1]]
#> [1] "encode:ENCSR970ACM"
#>
#>
#> $annotation$original_file_name
#> [1] "ENCFF370XZK.bed.gz"
#>
#>
#> $processed
#> [1] FALSE
#>
#> $stats
#> NULL
#>
#> $plots
#> NULL
#>
#> $files
#> NULL
#>
#> $universe_metadata
#> NULL
#>
#> $bedsets
#> list()
#>