
Options and environment variables used by isoformic
Source:R/isoformic-options.R
isoformic-options.Rdisoformic has one package option, isoformic.frozen_mirrors, and is
otherwise configured through base R options, the environment variables
that locate the user cache and the settings of the packages it builds on.
This page lists every setting the package reads or is affected by, what
it changes and where it is used. Settings are read at call time, so they
can be changed with options() / Sys.setenv() in a session, scoped
with withr::with_options() / withr::with_envvar(), or placed in
.Rprofile / .Renviron.
Package options
isoformic.frozen_mirrorsCharacter vector of base URLs tried first by
fetch_frozen_data()(and every function that loads a frozen dataset, such asadd_appris()orpolya_sites(polya_atlas = "polyasite")) before thefrozen-dataGitHub release and the Zenodo record returned byfrozen_mirrors(). Each URL is joined with the file name of the dataset, for exampleoptions(isoformic.frozen_mirrors = "https://zenodo.org/records/<id>/files/")pins an analysis to one Zenodo deposit, and"file:///data/isoformic-frozen/"serves the files from a local or institutional mirror. The MD5 recorded infrozen_datasets()is verified whatever the mirror. Default: unset (no extra mirror).
Base R options
timeoutTimeout in seconds of
utils::download.file()andurl()connections.download_reference(),download_reference_url(),download_hprc_annotation(),download_fantom_cat_tables(),fetch_frozen_data()and the builders in build_frozen_data raise it, for the duration of the download only, to at least thetimeout_limitof the call (3600 seconds by default, large reference files are several gigabytes) and never lower it. Set a larger value for slow connections.download.file.method,download.file.extraDefine what the
method = "auto"default of the download functions resolves to and the extra command line flags of the"wget"and"curl"methods. Passmethodexplicitly to override them for one call.rlang_interactiveOverrides
interactive()forrlang::is_interactive(). In a non-interactive session the download progress is silenced (quiet = TRUEinutils::download.file()) and missing optional packages (fgsea,condathis,readxl,SummarizedExperiment) raise an error instead of an installation prompt.cli.num_colors,cli.unicode,cli.default_handler,cli.width,cli.progress_show_afterRendering of every message, warning and error, which the package emits through the
clipackage.cli.unicode = FALSEandcli.num_colors = 1produce plain ASCII output for logs; see?cli::cli-config.
Environment variables
R_USER_CACHE_DIR,XDG_CACHE_HOMERoot of the user cache.
get_isoformic_cache()resolvestools::R_user_dir("isoformic", "cache"), which honoursR_USER_CACHE_DIRfirst, thenXDG_CACHE_HOME(~/.cacheby default on Linux). On macOS the package setsXDG_CACHE_HOMEto~/.cachefor the lookup when it is unset, so the cache lives in~/.cache/R/isoformic/instead of~/Library/Caches/org.R-project.R/R/isoformic/and never contains a space. The cache holds downloaded references (download_reference()), the frozen datasets (frozen/), their sources (sources/<name>/) and the Zenodo bundle (zenodo_deposit/). Point it to a shared or scratch disk on HPC systems.LOCALAPPDATAOn Windows, the root that
tools::R_user_dir()uses whenR_USER_CACHE_DIRis unset.HOME,USERPROFILEDefine the
~that the defaults above andfs::path_home()expand to.http_proxy,https_proxy,ftp_proxy,no_proxyProxy settings honoured by
utils::download.file()andurl()(libcurlandinternalmethods) and therefore by every download in the package, including the connectivity checkcurl::has_internet().CURL_CA_BUNDLE,SSL_CERT_FILECertificate bundle used by the
libcurldownload method, needed behind TLS-intercepting proxies.
Settings of other packages
- DuckDB
Every Parquet read and write (
read_parquet(),write_parquet(),read_tabular()) and the heavy joins run in a short-lived in-memory DuckDB connection with the DuckDB defaults: all CPU cores (threads), 80% of the RAM asmemory_limitand a.tmpdirectory under the working directory when a query spills to disk. The package does not expose these; they are DuckDB session settings and the connections are not shared with user code.condathis.micromamba_path,CONDATHIS_MICROMAMBA_PATH,CONDA_PREFIX,XDG_DATA_HOMERead by the
condathispackage, whichsalmon_index()andsalmon_quant()use to runsalmonin a micromamba environment: where themicromambabinary is found and where environments are created. See?condathis::condathis.BIOCONDUCTOR_*,R_LIBS*Only relevant for installing the optional packages (
fgsea,SummarizedExperiment); the package itself does not read them.
Development and test settings
These are not read by the package code but control its test suite and
checks (see justfile):
TESTTHAT_CPUSNumber of parallel testthat workers used by
just test.NOT_CRANSet to
"true"bydevtools::test(); tests that need optional packages usetestthat::skip_if_not_installed()rather than network access, so no test downloads data._R_CHECK_SYSTEM_CLOCK_Set to
"0"byjust checkto skip the clock check ofR CMD check --as-cran.HOME,R_USER_CACHE_DIR,XDG_CACHE_HOME,R_USER_DATA_DIR,XDG_DATA_HOME,LOCALAPPDATA,APPDATAThe test setup redirects all of them to temporary directories so that tests never touch the user cache.
Examples
# Pin the frozen datasets to one Zenodo deposit for a reproducible run
withr::with_options(
list(isoformic.frozen_mirrors = "https://zenodo.org/records/1234567/files/"),
frozen_mirrors()
)
#> [1] "https://zenodo.org/records/1234567/files/"
#> [2] "https://github.com/luciorq/isoformic/releases/download/frozen-data/"
# Where the cache is, and how to move it
get_isoformic_cache()
#> /home/runner/.cache/R/isoformic
withr::with_envvar(
list(R_USER_CACHE_DIR = tempdir()),
get_isoformic_cache("frozen")
)
#> /tmp/RtmpV2WK1u/R/isoformic/frozen