macroConvertBin: Converts MACRO/SOIL binary files into CSV or TXT text files

View source: R/macroutils2.r

macroConvertBinR Documentation

Converts MACRO/SOIL binary files into CSV or TXT text files

Description

Converts MACRO/SOIL binary files into CSV or TXT text files. The function is a wrapper around macroReadBin and write.table. It is possible to choose the field delimiter and the decimal mark.

Usage

macroConvertBin(
  f,
  gui = TRUE,
  sep = ",",
  dec = ".",
  fileOut = NULL,
  writeArgs = list(row.names = FALSE),
  overwrite = FALSE,
  ...
)

Arguments

f

Vector of character strings or a single connection to a binary file. If a vector character strings, it should be the name(s) of the binary file(s) which the data are to be read from. The path of the file(s) may be provided as well, if the file(s) is (are) not in the working directory.

gui

Single logical. Set to TRUE if you want to choose only some of the columns in the table passed to x. Will be ignored if interactive is FALSE (i.e. if ran outside R GUI for Windows).

sep

Single character. Columns / field separator. Ignored if gui=TRUE. Choose ',' for comma, ';' for semi-colon, '\t' for tabulation and ' ' for space.

dec

Single character. Decimal mark. Ignored if gui=TRUE.

fileOut

Vector of character strings or a single connection to a text. If a vector character strings, it should be the name(s) of the text file(s) where the data are to be written to. The path of the file(s) may be provided as well, if these file(s) is (are) not in the working directory. If NULL, file names will be generated automatically.

writeArgs

List of additional arguments passed to write.table

overwrite

Single logical value. If TRUE (not the default), Existing output files are overwritten without warning.

...

More arguments passed to macroReadBin.


julienmoeys/macroutils2 documentation built on Feb. 28, 2024, 2:17 a.m.