Package 'RBCFTools'

Title: Packaged 'BCFtools' and 'HTSlib' Command-Line Tools
Description: Builds and installs pinned 'bcftools' and 'htslib' command-line tools, including packaged plugins such as liftover and score. Provides executable discovery, deterministic plugin environment configuration, version inspection, and structured process execution. Variant table, 'DuckDB', 'DuckLake', Arrow, Parquet, and annotation APIs are intentionally owned by 'Rduckhts' rather than duplicated here.
Authors: Sounkou Mahamane Toure [aut, cre], Abiomix FZ LLC [cph, fnd] (Copyright holder and funder of Abiomix contributions), Bonfield, James K and Marshall, John and Danecek, Petr and Li, Heng and Ohan, Valeriu and Whitwham, Andrew and Keane, Thomas Davies, Robert M, Pierre Lindenbaum [cph] (Authors of included htslib library and bcftools command line tools), Zilong Li [cph] (Author of the vcfpp library from whom makefiles and configure strategy is borrowed), Giulio Genovese [cph] (Author of BCFTools munge plugin)
Maintainer: Sounkou Mahamane Toure <[email protected]>
License: GPL (>= 3)
Version: 1.23-0.0.4.9000
Built: 2026-07-13 11:51:18 UTC
Source: https://github.com/abiomix/abiomix-r-open

Help Index


Run the packaged bcftools executable

Description

Run the packaged bcftools executable

Usage

bcftools_run(
  args = character(),
  stdin = NULL,
  error_on_status = TRUE,
  echo = FALSE,
  timeout = Inf,
  env = character()
)

Arguments

args

A character vector passed directly to the executable.

stdin

Optional standard input accepted by processx::run().

error_on_status

Whether a non-zero exit status raises an error.

echo

Whether to echo child output while the process runs.

timeout

Process timeout in milliseconds; Inf disables it.

env

Optional named environment overrides.

Value

A processx::run() result with status, stdout, and stderr.


Locate a packaged native executable

Description

Locate a packaged native executable

Usage

rbcftools_binary(
  tool = c("bcftools", "bgzip", "tabix", "htsfile", "annot-tsv", "ref-cache")
)

bcftools_path()

bgzip_path()

tabix_path()

htsfile_path()

annot_tsv_path()

ref_cache_path()

Arguments

tool

One of bcftools, bgzip, tabix, htsfile, annot-tsv, or ref-cache.

Value

The normalized absolute path to the executable.


Report the installed binary surface

Description

Report the installed binary surface

Usage

rbcftools_capabilities()

Value

A list containing versions, executables, and bcftools plugins.


Locate packaged tool directories

Description

Locate packaged tool directories

Usage

bcftools_bin_dir()

htslib_bin_dir()

bcftools_plugins_dir()

htslib_plugins_dir()

Value

The package path for the requested binary or plugin directory.


List packaged tools and plugins

Description

List packaged tools and plugins

Usage

bcftools_tools()

htslib_tools()

bcftools_plugins()

Value

A character vector of installed names.


Run a packaged native tool

Description

Run a packaged native tool

Usage

rbcftools_run(
  tool,
  args = character(),
  stdin = NULL,
  error_on_status = TRUE,
  echo = FALSE,
  timeout = Inf,
  env = character()
)

Arguments

tool

One of the names accepted by rbcftools_binary().

args

A character vector passed directly to the executable.

stdin

Optional standard input accepted by processx::run().

error_on_status

Whether a non-zero exit status raises an error.

echo

Whether to echo child output while the process runs.

timeout

Process timeout in milliseconds; Inf disables it.

env

Optional named environment overrides.

Value

A processx::run() result with status, stdout, and stderr.


Inspect packaged native-tool versions

Description

Inspect packaged native-tool versions

Usage

rbcftools_versions()

bcftools_version()

htslib_version()

Value

rbcftools_versions() returns a named character vector. bcftools_version() and htslib_version() return one version string.


Configure native-tool plugin lookup for the current R process

Description

Child processes launched by rbcftools_run() receive these values without mutating the R process. Call this function only when another launcher needs the variables in the current environment.

Usage

setup_hts_env()

Value

Invisibly, the previous named values of HTS_PATH and BCFTOOLS_PLUGINS.