Learn R Programming

BIOdry (version 0.9)

cClass: Column-class extraction.

Description

Column names of multilevel data sets are extracted according to three classes: numeric values, integer sequences, and factor levels.

Usage

cClass(rd, cl = "all")

Value

character names.

Arguments

rd

data.frame. Multilevel data series.

cl

character or NULL. Character vector of classes to be considered. These can be 'numeric', 'integer', or 'factor'. If 'all' then all column names of rd are extracted.

Author

Wilson Lara <wilarhen@gmail.com>, Felipe Bravo <fbravo@pvs.uva.es>

Examples

Run this code
##Multilevel data frame of tree-ring widths:
data(Prings05,envir = environment())
## Names of variables in Prings05 data containing numeric classes:
cClass(Prings05, 'numeric') # 'x'
## Names of variables containing time units: 
cClass(Prings05, 'integer') # 'year'
## Names of variables containing factors: 
cClass(Prings05, 'factor') # 'sample', 'tree', 'plot'

Run the code above in your browser using DataLab