Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

mutate.skim_df

Mutate a skim_df


Description

dplyr::mutate() currently drops attributes, but we need to keep them around for other skim behaviors. Otherwise the behavior is exactly the same. For more information, see https://github.com/tidyverse/dplyr/issues/3429.

Usage

## S3 method for class 'skim_df'
mutate(.data, ...)

Arguments

.data

A skim_df, which behaves like a tbl.

...

Name-value pairs of expressions, each with length 1 or the same length as the number of rows in the group, if using dplyr::group_by(), or in the entire input (if not using groups). The name of each argument will be the name of a new variable, and the value will be its corresponding value. Use NULL value in dplyr::mutate() to drop a variable. New variables overwrite existing variables of the same name.

The arguments in ... are automatically quoted with rlang::quo() and evaluated with rlang::eval_tidy() in the context of the data frame. They support unquoting rlang::quasiquotation and splicing. See vignette("programming", package = "dplyr") for an introduction to these concepts.

Value

A skim_df object, which also inherits the class(es) of the input data. In many ways, the object behaves like a tibble::tibble().

See Also

dplyr::mutate() for the function's expected behavior.


skimr

Compact and Flexible Summaries of Data

v2.1.3
GPL-3
Authors
Elin Waring [cre, aut], Michael Quinn [aut], Amelia McNamara [aut], Eduardo Arino de la Rubia [aut], Hao Zhu [aut], Julia Lowndes [ctb], Shannon Ellis [aut], Hope McLeod [ctb], Hadley Wickham [ctb], Kirill Müller [ctb], RStudio, Inc. [cph] (Spark functions), Connor Kirkpatrick [ctb], Scott Brenstuhl [ctb], Patrick Schratz [ctb], lbusett [ctb], Mikko Korpela [ctb], Jennifer Thompson [ctb], Harris McGehee [ctb], Mark Roepke [ctb], Patrick Kennedy [ctb], Daniel Possenriede [ctb], David Zimmermann [ctb], Kyle Butts [ctb], Bastian Torges [ctb], Rick Saporta [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.