write_gasexchange {gasanalyzer}R Documentation

Write a gas-exchange tibble to a text file.

Description

The column names and column units are saved as a two-row header. The files use UTF-16LE and CRLF line headings for compatibility. By default, tabs are used as delimiter. If you intend to open the file in a spreadsheet program, it may be helpful to use csv as file extension.

Usage

write_gasexchange(df, filename, delim = "\t")

Arguments

df

a tibble with gas-exchange data

filename

path to the output file

delim

delimiter to use for the file

Details

Note that for data-exchange between R sessions, saveRDS() and readRDS() are faster, and support saving and loading list columns (such as calibration information and equations). This method is primarily meant for exchanging data with other software packages.

Value

No return value. If there a problems writing the file, a warning or error will be shown.

Examples


example <- system.file("extdata//d13C.tsv", package = "gasanalyzer")

# read data and recalculate using default gas-exchange equations:
df <- read_gasexchange(example) |>
  recalculate(create_equations("default"))

# write recaculated data
write_gasexchange(df, "d13C_recalculated.tsv")


[Package gasanalyzer version 0.4.0 Index]