Learn R Programming

safetyGraphics (version 2.1.1)

hasColumn: Check whether a column is found in a data set

Description

Checks whether a specified column is found in a specified data set

Usage

hasColumn(columnName, data)

Value

logical scalar. TRUE if the column is found. FALSE otherwise

Arguments

columnName

The column to look for.

data

the data.frame to search.

Examples

Run this code
safetyGraphics:::hasColumn(columnName="PARAM",data=safetyData::adam_adlbc) #TRUE
safetyGraphics:::hasColumn(columnName="Not_a_column",data=safetyData::adam_adlbc) #FALSE

Run the code above in your browser using DataLab