select: select columns of a data.frame

selectR Documentation

select columns of a data.frame

Description

Select columns of a data.frame.

Usage

select_(df, variable = NULL)

Arguments

df

data.frame

variable

formula that describes the selection

Value

select_() returns a data frame. Properties:

  • Only columns following the condtion determined by

  • variable appear.

  • Rows are not modified.

Examples


  tmp <- select_(CO2,~Type)
  head(tmp)

  tmp <- select_(CO2,~c(Plant,Type))
  head(tmp)

  tmp <- select_(CO2,~-Type)
  head(tmp)

  tmp <- select_(CO2,variable=~-(Plant:Treatment))
  head(tmp)

pv71u98h1/m61r documentation built on Oct. 20, 2024, 6:29 p.m.