R/obs_catch_or_sample_weight_null_control.R
obs_catch_or_sample_weight_null_control.RdIdentifies in the observer data catches or samples all individual weights = 0 or NA.
obs_catch_or_sample_weight_null_control(data)data.frame expected. All catches or samples during the time range selected.
The function returns one data.frame.
The input dataframes must contain all these columns for the function to work :
catch_id
catch_weight
Or
samplemeasure_id
sample_weight
Version 1.0
#Catch 1 is ok: the catch's weight is > 0,
#Catch 2 is not ok: the catch's weight is = 0,
#Catch 3 is not ok: the catch's weight is NA.
catch <- data.frame(catch_id = c("1", "2", "3"),
catch_weight = c("5", "0", NA))
obs_catch_or_sample_weight_null_control(catch)
#> catch_id weight logical
#> 1 1 5 TRUE
#> 2 2 0 FALSE
#> 3 3 <NA> FALSE