get_contamination_probabilities | R Documentation |
Get probabilities of contamination
get_contamination_probabilities(params_df, show_progress = FALSE)
params_df |
|
show_progress |
boolean, whether or not to show progress bar |
params_df
must contain the following named columns:
z1
, z2
, rs
, density
, area
must be units
objects.
self_treat
is a boolean
theta_range
should be in radians as c(theta_min, theta_max)
alpha_range
should be in radians as c(alpha_min, alpha_max)
hh_array_type
character as "septic" or "well" (see get_septic_well_array
)
library(units)
library(tidyr)
params_row <- tibble(
z1 = set_units(10, "ft"),
z2 = set_units(20, "ft"),
area = set_units(64, "acre"),
theta_range = list(c(0, pi/4)), # this will be unlisted in the function
alpha_range = list(c(0, 20)), # this will be unlisted in the function
hh_array_type = "septic")
# This function allows multiple rows to be calculated at once
params_df <- params_row %>%
crossing(density = set_units(c(0, 0.5), "1/acre"),
rs = set_units(c(10, 20),"ft"), self_treat = c(TRUE, FALSE))
params_df$probs <- get_contamination_probabilities(params_df)
params_df
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.