run_afni_command: Wrapper for running an AFNI command safely within R

View source: R/glm_helper_functions.R

run_afni_commandR Documentation

Wrapper for running an AFNI command safely within R

Description

Wrapper for running an AFNI command safely within R

Usage

run_afni_command(
  args,
  afnidir = NULL,
  stdout = NULL,
  stderr = NULL,
  echo = TRUE,
  omp_num_threads = 1L,
  ...
)

Arguments

args

AFNI command string to be run

afnidir

Location of AFNI installation. If NULL, the function will search the environment for AFNIDIR or afni on PATH

stdout

File target for redirecting stdout. If NULL, stdout will not be written to file.

stderr

File target for redirecting stderr. If NULL, stderr will not be written to file.

echo

Whether to print AFNI command to the screen. Default: TRUE

omp_num_threads

sets the number of OpenMP threads used for this AFNI command (if supported)

...

Arguments passed through to the 'system' command.

Details

This command ensures that AFNI commands are run in an environment that is setup correctly

Value

The exit status of the executed AFNI command. 0 for success, non-zero for failure

Author(s)

Michael Hallquist

Examples


## Not run: 
run_afni_command("3dcopy test_data copy_data")

## End(Not run)

UNCDEPENdLab/fmri.pipeline documentation built on April 3, 2025, 3:21 p.m.