From e76b7f3e37b371711b1888484f9c067f954b56f9 Mon Sep 17 00:00:00 2001 From: iskandari Date: Wed, 10 Jul 2024 21:09:21 -0400 Subject: [PATCH] added vpts validation function --- R/validate_vpts.R | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/R/validate_vpts.R b/R/validate_vpts.R index ec9ac99f..d3f69bc0 100644 --- a/R/validate_vpts.R +++ b/R/validate_vpts.R @@ -24,11 +24,10 @@ validate_datetime_format <- function(data, format) { #' @importFrom glue glue #' @importFrom dplyr select #' @examples -#' schema <- data('vpts_schema', package = 'bioRad') -#' df <- read.csv('path_to_your_data.csv') # Your VPTS csv -#' validate_vpts_df(df, schema) +#' my_vpts <- as.data.frame(example_vpts) +#' validate_vpts(my_vpts, schema) #' @export -validate_vpts_df <- function(df) { +validate_vpts <- function(df) { schema <- vpts_schema required_fields <- schema$fields$name[schema$fields$constraints.required == TRUE]