Learn R Programming

PhotoGEA (version 1.4.0)

read_cr3000: Reading a CR3000 data file

Description

Tool for reading output files created by Campbell Scientific CR3000 data loggers and storing their contents in exdf objects.

Usage

read_cr3000(
    file_name,
    rows_to_skip = 1,
    variable_name_row = 2,
    variable_unit_row = 3,
    data_start_row = 5,
    remove_NA_rows = TRUE,
    ...
  )

Value

An exdf object that fully includes all the data from the CR3000 output file. In addition to the elements described in the documentation for

read_gasex_file, the following "extra" elements are also included:

  • rows_to_skip: A copy of the input argument with the same name

  • variable_name_row: A copy of the input argument with the same name.

  • variable_unit_row: A copy of the input argument with the same name.

  • data_start_row: A copy of the input argument with the same name.

Arguments

file_name

A relative or absolute path to a .dat file containing TDL data.

rows_to_skip

The number of rows to skip at the beginning of the file; the first row in a TDL file typically has fewer columns than the others, which causes problems when storing it as a table.

variable_name_row

The row number in the TDL file containing the names of the variables (RECORD, Conc12C_Avg, etc).

variable_unit_row

The row number in the TDL file containing the units of the variables (ppm, V, etc).

data_start_row

The first row number of the table containing the measured data.

remove_NA_rows

A logical value indicating whether to remove any rows whose values are all NA.

...

Additional arguments to be passed to read.csv.

See Also

read_gasex_file

Examples

Run this code
# Example: reading a TDL file that is included with the PhotoGEA package.
tdl_file <- read_cr3000(
  PhotoGEA_example_file_path('tdl_sampling_1.dat')
)

tdl_file$file_name # A record of where the data came from
str(tdl_file)      # View the contents of the exdf object's main_data

Run the code above in your browser using DataLab