remove.column: Remove columns

Description Usage Arguments Value Examples

View source: R/classes.R

Description

Removes specified column from df or breaks with message if column not in df's columns names

Usage

1
remove.column(df, column)

Arguments

df

data.frame

column

character column name

Value

data.frame

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
remove.column(data.frame(x=c(1:3), y = c(1:3)), column = "y")
#   x
# 1 1
# 2 2
# 3 3
remove.column(data.frame(x=c(1:3), y = c(1:3)), column = "value")
#   Can't remove column
# value
# Error in remove.column(data.frame(x = c(1:3), y = c(1:3)), column = "value") :
# no loop for break/next, jumping to top level

mkhlgrv/rmen documentation built on Dec. 21, 2021, 7:06 p.m.