powered by
Function to test column names of a data being different from what specified
test_columnnames(column_names, data)
0, if success error, if failure
column names of the data frame
a data frame
test_columnnames(c("name", "age"), data.frame( "Age" = c(21, 15), "Name" = c("John", "Dora") ))
Run the code above in your browser using DataLab