Description Usage Arguments Value Examples
Adjust values based on the barometric efficiency
1 2 | be_correct(dat, dep = "wl", ind = "baro", be = 0, inverse = TRUE,
known_mean = NULL)
|
dat |
data that has the independent and dependent variables (data.table) |
dep |
name of the dependent variable column (character). This is typically the name for the column holding your water level data. |
ind |
name of the independent variable column (character). This is typically the name for the column holding your barometric pressure data. |
be |
|
inverse |
whether the barometric relationship is inverse (TRUE means that when the barometric pressure goes up the measured water level goes down (vented transducer, depth to water), FALSE means that when the barometric pressure goes up so does the measured pressure (non-vented transducer)) (logical). |
known_mean |
|
numeric vector
of corrected values
1 2 3 4 5 6 7 | library(data.table)
baro = rnorm(1000, sd = 0.01) + 9
wl <- baro * 0.4 + 18
dat <- data.table(baro, wl)
dat$wl + be_correct(dat, be=0.4, inverse = FALSE)
dat$wl + be_correct(dat, be=0.4, inverse = FALSE, known_mean = 9)
# should return ~21.6 = 18 + 0.4 * 9
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.