taudem_exec {traudem} | R Documentation |
Call TauDEM
Description
Call TauDEM
Usage
taudem_exec(
program,
args,
...,
n_processes = getOption("traudem.n_processes", 1),
quiet = getOption("traudem.quiet", FALSE)
)
Arguments
program |
TauDEM command (character). See examples. |
args |
Character vector of arguments. See examples. |
... |
These dots are for future extensions and must be empty. As a consequence, all following arguments must be fully named (see examples). |
n_processes |
Number of processes for |
quiet |
If |
Details
You can use this function to call more TauDEM methods than the ones with dedicated wrappers in this package. Please refer to the relative TauDEM function documentation for the syntax used to specify optional arguments. See also examples.
Value
TRUE
if the call was successful, FALSE
otherwise.
Examples
test_dir <- withr::local_tempdir()
dir.create(test_dir)
file.copy(
system.file("test-data", "DEM.tif", package = "traudem"),
file.path(test_dir, "DEM.tif")
)
# Default name for output file, only input command and input filename.
taudem_exec("pitremove", file.path(test_dir, "DEM.tif"))
# syntax for user-attributed output file name
taudem_exec(
"pitremove",
c(
"-z", file.path(test_dir, "DEM.tif"),
"-fel", file.path(test_dir,"filled_pits.tif")
)
)
[Package traudem version 1.0.3 Index]