warn_if_vars_exist: Warn If a Variable Already Exists

Description Usage Arguments Author(s) Examples

View source: R/warnings.R

Description

Warn if a variable already exists inside a dataset

Usage

1

Arguments

dataset

A data.frame

vars

character vector of columns to check for in dataset

Author(s)

Thomas Neitmann

Examples

1
2
3
4
5
6
7
8
library(admiral.test)
data(dm)

## No warning as `AAGE` doesn't exist in `dm`
warn_if_vars_exist(dm, "AAGE")

## Issues a warning
warn_if_vars_exist(dm, "ARM")

epijim/admiral documentation built on Feb. 13, 2022, 12:15 a.m.