rowwise: Group input by rows

Description Usage Arguments Details Value Examples

View source: R/dplyr_methods.R

Description

See [this repository](https://github.com/jennybc/row-oriented-workflows) for alternative ways to perform row-wise operations.

Usage

1
rowwise(.data)

Arguments

.data

Input data frame.

Details

'rowwise()' is used for the results of [do()] when you create list-variables. It is also useful to support arbitrary complex operations that need to be applied to each row.

Currently, rowwise grouping only works with data frames. Its main impact is to allow you to work with list-variables in [summarise()] and [mutate()] without having to use [[1]]. This makes 'summarise()' on a rowwise tbl effectively equivalent to [plyr::ldply()].

Value

A 'tbl'

A 'tbl'

Examples

1
2
3
`%>%` = magrittr::`%>%`
df <- expand.grid(x = 1:3, y = 3:1)
df_done <- df %>% rowwise() %>% do(i = seq(.$x, .$y))

tidybulk documentation built on April 7, 2021, 6 p.m.