Learn R Programming

Rnmr1D (version 1.2.5)

setLogFile: setLogFile

Description

setLogFile allows to redirect all log messages to a file

Usage

setLogFile(con = stdout())

Arguments

con

a connection object which inherits from class "connection"

Examples

Run this code
# NOT RUN {
 
# }
# NOT RUN {
  # Redirect all log messages to a temporary file
   outtmp <- tempfile()
   con <- file(outtmp, "wt", encoding = "UTF-8")
   setLogFile(con)
   data_dir <- system.file("extra", package = "Rnmr1D")
   RAWDIR <- file.path(data_dir, "CD_BBI_16P02")
   CMDFILE <- file.path(data_dir, "NP_macro_cmd.txt")
   SAMPLEFILE <- file.path(data_dir, "Samples.txt")
   out <- Rnmr1D::doProcessing(RAWDIR, cmdfile=CMDFILE, samplefile=SAMPLEFILE, ncpu=6)
   close(con)
   readLines(outtmp)
 
# }

Run the code above in your browser using DataLab