Description Usage Arguments Value Examples
Calculate the barometric efficiency using the mean (or other statistic) of the water level change divided by the barometric pressure change . There is the option to only include responses that are large.
1 2 |
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. |
lag_space |
space between difference calculation in number of observations |
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). |
quant |
quantile cutoff value that differences need to be this large (numeric) |
stat |
the result to return (mean, median, quantile) (function) |
... |
other arguments to pass to "stat" |
barometric efficiency calculated by using ratio method
1 2 3 4 5 6 7 8 9 | library(data.table)
datetime <- seq.POSIXt(as.POSIXct("2016-01-01 12:00:00"),
as.POSIXct("2016-01-05 12:00:00"), by='hour' )
baro <- sin(seq(0, 2*pi, length.out = length(datetime)))
noise <- rnorm(length(datetime), sd = 0.01)
wl <- -0.4 * baro + noise
dat <- data.table(baro, wl, datetime)
be_ratio(dat, quant = 0.5, stat=median)
be_ratio(dat, quant = 0.9, stat=mean)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.