Skip to content

Commit

Permalink
passing r cmd check
Browse files Browse the repository at this point in the history
  • Loading branch information
GabrielSlPires committed May 25, 2024
1 parent b87ef08 commit 6bd8ac8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions R/calculateGasDischarged.R
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ setGeneric("calculateGasDischarged", function(object, pressure_interval = 15, re
setMethod("calculateGasDischarged", "PneumatronDatabase", function(object, pressure_interval = 15, reservoir = 2.6, p_atm = 101.3, fixed_p_atm = TRUE, temp = 25, fixed_temp = TRUE, R = 8.3144621) {
# Prevent 'no visible binding for global variable ...' warnings by initializing to NULL
# Reference: https://github.com/Rdatatable/data.table/issues/850
pi <- pf <- temp1 <- pressure_diff <- gd_mol <- NULL
p_atm_calc <- sensor_p_atm <- temp_calc <- sensor_temp <- pi <- pf <- temp1 <-
pressure_diff <- gd_mol <- gd_ul <- n_mol <- NULL

reservoir_volume <- reservoir * 10^-6
data <- get_data(object)
Expand Down Expand Up @@ -72,7 +73,8 @@ setMethod("calculateGasDischarged", "PneumatronDatabase", function(object, press
prepare_data_for_gas_discharged <- function(data, pressure_interval) {
# Prevent 'no visible binding for global variable ...' warnings by initializing to NULL
# Reference: https://github.com/Rdatatable/data.table/issues/850
. <- datetime <- log_line <- temp1 <- .N <- pressure <- id <- measure <- group <- NULL
log_line_count <- .N <- id <- measure <- group <- version <- . <- datetime <-
log_line <- temp1 <- pressure <- NULL

# filter gas discharged measurements with less than required pressure logs
data[, log_line_count := .N, by = list(id, measure, group, version)]
Expand Down

0 comments on commit 6bd8ac8

Please sign in to comment.