Learn R Programming

mmodely (version 0.2.5)

cept: Include all variables except ...

Description

This function takes a dataframe, list, or a named vector of variable (column) names to subset

Usage

cept(x,except='gn_sp')

Value

the subset of x without those 'except' items specified

Arguments

x

a dataframe, list, or named vector

except

a vector of the names of the items in x to exclude

Examples

Run this code

data.path <- system.file("extdata","primate-example.data.csv", package="mmodely")
data <- read.csv(data.path, row.names=1)

df.except.gnsp <- cept(x=data,except='gn_sp')

Run the code above in your browser using DataLab