transmutate: Drop only columns used in formula

View source: R/wrangling_data.R

transmutateR Documentation

Drop only columns used in formula

Description

A function between dplyr's transmute and mutate

Usage

transmutate(.data, ...)

Arguments

.data

Data frame to pass to the function

...

Variables to pass to the function

Value

Data frame with mutated variables and none of the variables used in the mutations, but, unlike dplyr::transmute(), all other unnamed variables.

Source

https://stackoverflow.com/questions/51428156/dplyr-mutate-transmute-drop-only-the-columns-used-in-the-formula

Examples

pluck(emperors, "wikipedia")
transmutate(emperors$wikipedia, Beginning = Beg)

globalgov/qData documentation built on April 10, 2022, 8:48 a.m.