Apply QC flags to Argo data
argo_qc_censor_if_not(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_censor_if(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_keep_if_all(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_keep_if_any(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_discard_if_all(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_discard_if_any(
tbl,
cols,
qc_flag,
qc_cols = argo_qc_cols(tbl, { { cols } })
)
argo_qc_cols(tbl, cols)
A data frame containing _qc
or _QC
columns.
Columns in tbl
, specified using dplyr::select()
syntax.
One or more quality control flags. See
argo_reference_qc_flag
for long-form descriptions of integer qc_flag
values.
A vector of columns that contain the quality control flag values found in columns.
A modified tbl
.
library(dplyr, warn.conflicts = FALSE)
with_argo_example_cache({
argo_prof_levels("dac/csio/2902746/profiles/BR2902746_001.nc") %>%
argo_qc_censor_if_not(doxy, qc_flag = c(1, 2, 8))
})
#> Extracting from 1 file
#> # A tibble: 101 × 15
#> file n_levels n_prof pres c1phase_doxy c1phase_doxy_qc c2phase_doxy
#> <chr> <int> <int> <dbl> <dbl> <chr> <dbl>
#> 1 csio/2902746… 1 1 0.200 35.3 0 5.62
#> 2 csio/2902746… 2 1 0.900 35.4 0 5.61
#> 3 csio/2902746… 3 1 1.90 35.5 0 5.60
#> 4 csio/2902746… 4 1 2.90 35.6 0 5.60
#> 5 csio/2902746… 5 1 4 35.6 0 5.59
#> 6 csio/2902746… 6 1 5 35.6 0 5.59
#> 7 csio/2902746… 7 1 6 35.6 0 5.59
#> 8 csio/2902746… 8 1 7.10 35.6 0 5.58
#> 9 csio/2902746… 9 1 8.20 35.6 0 5.58
#> 10 csio/2902746… 10 1 9.30 35.6 0 5.58
#> # … with 91 more rows, and 8 more variables: c2phase_doxy_qc <chr>,
#> # temp_doxy <dbl>, temp_doxy_qc <chr>, doxy <dbl>, doxy_qc <chr>,
#> # doxy_adjusted <dbl>, doxy_adjusted_qc <chr>, doxy_adjusted_error <dbl>