The history_qctest
column in argo_prof_history()
and
argo_traj_history()
is a binary flags column, allowing a single integer
value to represent up to 32 logical values. This function expands its
input such that there is one test represented by each row and can be
joined to argo_reference_history_qctest
on the history_qctest
column.
argo_unnest_history_qctest(tbl)
A data frame with a history_qctest
column.
tbl
library(dplyr, warn.conflicts = FALSE)
with_argo_example_cache({
argo_prof_history(
"dac/csio/2902746/profiles/BR2902746_001.nc",
vars = "history_qctest"
) %>%
argo_unnest_history_qctest() %>%
left_join(argo_reference_history_qctest, by = "history_qctest") %>%
select(history_qctest_description, everything())
})
#> Extracting from 1 file
#> # A tibble: 20 × 7
#> history_qctest_des… file n_prof n_history history_qctest history_qctest_…
#> <chr> <chr> <int> <int> <chr> <int>
#> 1 Platform Identific… csio/29… 1 1 2 1
#> 2 Impossible Date te… csio/29… 1 1 4 2
#> 3 Impossible Locatio… csio/29… 1 1 8 3
#> 4 Position on Land t… csio/29… 1 1 10 4
#> 5 Impossible Speed t… csio/29… 1 1 20 5
#> 6 Global Range test csio/29… 1 1 40 6
#> 7 Regional Global Pa… csio/29… 1 1 80 7
#> 8 Pressure Increasin… csio/29… 1 1 100 8
#> 9 Spike test csio/29… 1 1 200 9
#> 10 Gradient test csio/29… 1 1 800 11
#> 11 Digit Rollover test csio/29… 1 1 1000 12
#> 12 Stuck Value test csio/29… 1 1 2000 13
#> 13 Density Inversion … csio/29… 1 1 4000 14
#> 14 Gross Salinity or … csio/29… 1 1 10000 16
#> 15 Frozen profile test csio/29… 1 1 3FC18 18
#> 16 Deepest pressure t… csio/29… 1 1 80000 19
#> 17 Global Range test csio/29… 1 3 40 6
#> 18 Spike test csio/29… 1 3 200 9
#> 19 Gradient test csio/29… 1 3 800 11
#> 20 Frozen profile test csio/29… 1 3 3FC18 18
#> # … with 1 more variable: history_qctest_flag <int>