mutate {m61r}R Documentation

Mutate and transmutate a data.frame

Description

Mutate and transmutate a data.frame.

Usage

mutate_(df, ...)

transmutate_(df, ...)

Arguments

df

data.frame

...

formula used for mutating/transmutating the data.frame

Value

The functions return a data frame. The output has the following properties:

Examples

tmp <- mutate_(CO2,z=~conc/uptake)
head(tmp)

# Return an warning: expression mean(uptake) get a result with 'nrow' different from 'df'
# tmp <- mutate_(CO2,mean=~mean(uptake))

tmp <- mutate_(CO2,z1=~uptake/conc,y=~conc/100)
head(tmp)

tmp <- transmutate_(CO2,z2=~uptake/conc,y2=~conc/100)
head(tmp)

[Package m61r version 0.0.3 Index]