R/logbook_temperature_control.R
logbook_temperature_control.Rd
The purpose of the logbook_temperature_control function is to provide a table of data that contains an inconsistency between the sea surface temperature for the activity and valid threshold
logbook_temperature_control(dataframe1, output, threshold = c(15, 32))
data.frame expected. Csv or output of the function data_extraction, which must be done before using the logbook_temperature_control () function.
character expected. Kind of expected output. You can choose between "message", "report" or "logical".
numeric expected. Default values: 15 and 32. Vector containing the lower and upper acceptable threshold for sea surface temperature.
The function returns a character with output is "message", a data.frame with output is "report", a logical with output is "logical"
The input dataframe must contain all these columns for the function to work :
activity_id
activity_seasurfacetemperature
#Activity 1 is ok,
#Activity 2 and 3 have temperatures outside the thresholds
dataframe1 <- data.frame(activity_id = c("1", "2", "3"),
activity_seasurfacetemperature = c(20, 4, 35))
logbook_temperature_control(dataframe1, output = "report")
#> activity_id logical activity_seasurfacetemperature
#> 1 1 TRUE 20
#> 2 2 FALSE 4
#> 3 3 FALSE 35