rsaga.esri.to.sgrd: Convert ESRI ASCII/binary grids to SAGA grids

View source: R/RSAGA-modules.R

rsaga.esri.to.sgrdR Documentation

Convert ESRI ASCII/binary grids to SAGA grids

Description

rsaga.esri.to.sgrd converts grid files from ESRI's ASCII (.asc) and binary (.flt) format to SAGA's (version 2) grid format (.sgrd).

Usage

rsaga.esri.to.sgrd(
  in.grids,
  out.sgrds = set.file.extension(in.grids, ".sgrd"),
  in.path,
  ...
)

Arguments

in.grids

character vector of ESRI ASCII/binary grid files (default file extension: .asc); files should be located in folder in.path

out.sgrds

character vector of output SAGA grid files; defaults to in.grids with file extension being replaced by .sgrd, which is also the default extension if file names without extension are specified; files will be placed in the current SAGA workspace (default: rsaga.env()$workspace, or env$workspace if an env argument is provided

in.path

folder with in.grids

...

optional arguments to be passed to rsaga.geoprocessor(), including the env RSAGA geoprocessing environment

Value

The type of object returned depends on the intern argument passed to the rsaga.geoprocessor(). For intern=FALSE it is a numerical error code (0: success), or otherwise (default) a character vector with the module's console output.

If multiple in.grids are converted, the result will be a vector of numerical error codes of the same length, or the combination of the console outputs with c().

Note

This function uses module 1 from the SAGA library io_grid.

Author(s)

Alexander Brenning (R interface), Olaf Conrad (SAGA module)

See Also

rsaga.esri.wrapper() for an efficient way of applying RSAGA to ESRI ASCII/binary grids; rsaga.env()


RSAGA documentation built on Dec. 10, 2022, 1:12 a.m.