The purpose of the logbook_floating_object_operation_buoy_control function is to provide a table of data that contains a incoherent with the floating object operation and buoy operation

logbook_floating_object_operation_buoy_control(
  dataframe1,
  dataframe2,
  output,
  operation_object_buoy = list(`1` = c("2", "4", "5"), `2` = c("4"), `4` = c("3", "4"),
    `5` = c("1", "3", "4"), `7` = c("3"), `8` = c("4"), `9` = c("4"), `6` = c("3"), `11`
    = c("1", "2", "3"), `12` = c("3", "1"))
)

Arguments

dataframe1

data.frame expected. Csv or output of the function data_extraction, which must be done before using the logbook_floating_object_operation_buoy_control.

dataframe2

data.frame expected. Csv or output of the function data_extraction, which must be done before using the logbook_floating_object_operation_buoy_control.

output

character expected. Kind of expected output. You can choose between "message", "report" or "logical".

operation_object_buoy

list expected. Default values: list("1" = c("2", "4", "5"), "2" = c("4"), "4" = c("3", "4"), "5" = c("1", "3", "4"), "7" = c("3"), "8" = c("4"), "9" = c("4"), "6" = c("3"), "11" = c("1", "2", "3"), "12" = c("3", "1")). List of the inventory of floating object operation (left side) prohibited with buoy operation used (right side)

Value

The function returns a character with output is "message", a data.frame with output is "report", a logical with output is "logical".

Details

The input dataframe must contain all these columns for the function to work :

  • transmittingbuoy_id

  • transmittingbuoyoperation_code

  • floatingobject_id Dataframe 2:

  • floatingobject_id

  • objectoperation_code

Examples

# Buoy 1 and 2 are ok,
# Buoy 3 has incompatible buoy operations and object operations
dataframe1 <- data.frame(transmittingbuoy_id = c("1","2","3"),
                         transmittingbuoyoperation_code = c("1", "4", "1"),
                         floatingobject_id = c("1","2","2"))
dataframe2 <- data.frame(floatingobject_id = c("1","2"),
                         objectoperation_code = c("1", "11"))
logbook_floating_object_operation_buoy_control(dataframe1, dataframe2, output = "report")
#>   transmittingbuoy_id transmittingbuoyoperation_code objectoperation_code
#> 1                   1                              1                    1
#> 2                   2                              4                   11
#> 3                   3                              1                   11
#>   logical
#> 1    TRUE
#> 2    TRUE
#> 3   FALSE