View source: R/validate_input_df.R
validate_input_df | R Documentation |
Validates the input dataframe has the correct type, correct required column names, that the distribution is valid, that the column types are correct, and that the column values are greater than or equal to 0 when they are numeric.
validate_input_df(input_df, distribution)
input_df |
Dataframe containing option_name (str) and various other columns depending on the distribution type. See vignette for more details. |
distribution |
String of the distribution name |
Bool TRUE if all checks pass.
input_df <- tibble::tibble(
option_name = c("A", "B"),
sum_clicks = c(1000, 1000),
sum_conversions = c(100, 120)
)
validate_input_df(input_df, "conversion_rate")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.