rm.col: Delete specified columns for dataframe or matrix

Description Usage Arguments Value Author(s) References Examples

View source: R/rm.col.R

Description

Delete specified columns for dataframe or matrix.

Usage

1
rm.col(mat, to.rm = NULL)

Arguments

mat

a dataframe or matrix, must have column names.

to.rm

a character vector representing the column names that to be removed.

Value

A dataframe or matrix (according to the input data)with certain column deleted.

Author(s)

Jinlong Zhang [email protected]

References

None

Examples

1
2
3
4
x <- rnorm(600)
dim(x) <- c(20,30)
colnames(x) <- paste("col",1:30,sep = "")
rm.col(x, to.rm = c("col1", "col3", "col8", "col22", "col30"))

phylotools documentation built on May 29, 2017, 1:41 p.m.