LoadLGR: Load LGR data

Description Usage Arguments Value Examples

View source: R/Load.R

Description

A function used to load raw data from LGR Ultraportable Gas Analyzers to be called in the functions SelCue and FluxCal. This function removes the extra lines without data at the end of the data file output by LGR analyzer and convert the timestamps into POSIXct for further processing.

Usage

1
LoadLGR(file, time_format = "mdy_HMS", Ta_ignore = FALSE)

Arguments

file

A string contains the directory path and file name of the raw data. The data should be provided as what is exported from the LGR analyzer.

time_format

A string indicates the format of timestamps. Default: "mdy_HMS". It also takes the format "dmy_HMS" or "ymd_HMS", depending on the timestamps output from the analyzer.

Ta_ignore

A logic value indicates whether air temperature in the dataset is ignored. Default: FALSE. If this is set to "TRUE", the column name of the air temperature will not be checked, but air temperature data will have to be added to the argument df_Ta in the function FluxCal.

Value

A data frame with all data in the right format for the functions SelCue and FluxCal.

Examples

1
2
3
4
5
library(FluxCalR)
# get the directory of the example LGR raw data
example_data <- system.file("extdata", "Flux_example_1_LGR.txt", package = "FluxCalR")
# load the data
Flux <- LoadLGR(example_data)

junbinzhao/R-Package-FluxCalR documentation built on May 25, 2021, 5:49 a.m.