on_hostname: Evaluates an R Expression on One or More Hosts

View source: R/on_hostname.R

on_hostnameR Documentation

Evaluates an R Expression on One or More Hosts

Description

Evaluates an R Expression on One or More Hosts

Usage

on_hostname(hostnames, expr, ..., on_error = c("stop", "asis"), cache = FALSE)

Arguments

hostnames

A character vector of hostnames.

expr

The R expression to be evaluated on each host.

on_error

A character string specifying how to handle errors. If "stop" (default), then the error is relayed. If "asis", then the error (the base::condition object) is returned.

cache

If TRUE, cached results on file are considered.

...

(optional) Additional arguments passed to future::future().

Details

This function utilizes the future framework and specifically the future.batchtools package to evaluate the expression on a particular host by submitting it via the SGE scheduler.

Value

A named list with names hostnames.

Examples

## Not run: 
q <- available(queues())
hostnames <- sort(unique(q$hostname))
si <- on_hostname(hostnames, system_info())
print(si)

## End(Not run)


ucsf-wynton/wyntonquery documentation built on May 15, 2024, 6:23 a.m.