Extract Columns from a Dataset
DESCRIPTION:
Selects (subscript extraction) a column (or columns) from a 1- or 2-dimensional
dataset, retaining that dimensionality.
USAGE:
select.cols(x, columns)
REQUIRED ARGUMENTS:
- x
-
1- or 2-dimensional dataset whose column(s) will be selected. A 1-dimensional
dataset is considered to be a single, unnamed column.
- columns
-
logical, integer, or character vector specifying the column(s) of
x
which
is/are to be selected.
VALUE:
The subscript extraction of
columns
of
x
, with the same dimensionality as
x
.
SEE ALSO:
,
,
,
,
.
EXAMPLES:
fuel.both <- insert.col(fuel.frame, "@END", 2,
column.names=paste("orig",
name.cols(fuel.frame.orig)[1:2],
sep="."),
fill=select.cols(fuel.frame.orig, 1:2))