library(PhotoGEA)
?read_gasex_file
licor_file <- read_gasex_file(
PhotoGEA_example_file_path('ball_berry_1.xlsx'),
'time'
)
View(licor_file)
traceback()
View
View.data.frame
.rs.callAs
.rs.explorer.inspectObject
is.list(licor_file)
tmp <- list(a = 1, b = 2, c = 3)
View(tmp)
tmp2 <- data.frame(a = 1, b = 2, c = 3)
is.list(tmp2)
.rs.explorer.inspectList
View(licor_file$main_data)
names(licor_file)
.rs.slice
.rs.slice(licor_file, 1, 5)
tmpslice <- .rs.slice(licor_file, 1, 5)
View(tmpslice)
.rs.explorer.createContext()
tmpslice <- .rs.slice(licor_file, 1, 1000)
str(tmpslice)
length(tmpslice)
tmpslice[1]
names(licor_file)
?View
##------ [C:/Users/eloch/Documents/GitHub] Fri Aug 22 13:51:12 2025 ------##
remove.packages('PhotoGEA')
install.packages('licor-processing-and-analysis', repos=NULL, type='SOURCE')
library(PhotoGEA)
library(testthat)
test_dir('licor-processing-and-analysis/tests/testthat')
# Read an example Licor file included in the PhotoGEA package
licor_file <- read_gasex_file(
  PhotoGEA_example_file_path('c3_aci_1.xlsx')
)
# Define a new column that uniquely identifies each curve
licor_file[, 'species_plot'] <-
  paste(licor_file[, 'species'], '-', licor_file[, 'plot'] )
# Organize the data
licor_file <- organize_response_curve_data(
    licor_file,
    'species_plot',
    c(9, 10, 16),
    'CO2_r_sp',
    columns_to_average = c('Qin', 'TleafCnd')
)
# Calculate the total pressure in the Licor chamber
licor_file <- calculate_total_pressure(licor_file)
# Calculate temperature-dependent values of C3 photosynthetic parameters. Here
# we use the "Bernacchi" option, but override the Tp and gmc responses with a
# flat one.
licor_file <- calculate_temperature_response(
    licor_file,
    within(c3_temperature_param_bernacchi, {
        Tp_norm = c3_temperature_param_flat$Tp_norm
        gmc_norm = c3_temperature_param_flat$gmc_norm
    })
)
# Get just one curve
one_curve <- licor_file[licor_file[, 'species_plot'] == 'tobacco - 1', , TRUE]
# Purposely introduce negative Ci values
one_curve_bad <- one_curve
one_curve_bad[one_curve_bad[, 'CO2_r_sp'] == 20, 'Ci'] <- -5
colnames(one_curve)
rm(list=ls())
test_dir('licor-processing-and-analysis/tests/testthat')
?ball_berry_1.csv
setwd('licor-processing-and-analysis/inst/extdata/')
tmp <- read_gasex_file(PhotoGEA_example_file_path('ball_berry_1.xlsx')); write.csv.exdf(tmp, 'ball_berry_1.csv')
q()
