File: slice_rows.Rd

package info (click to toggle)
r-cran-purrrlyr 0.0.8-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 264 kB
  • sloc: cpp: 850; ansic: 258; sh: 13; makefile: 2
file content (31 lines) | stat: -rw-r--r-- 858 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rows.R
\name{slice_rows}
\alias{slice_rows}
\alias{unslice}
\title{Slice a data frame into groups of rows}
\usage{
slice_rows(.d, .cols = NULL)

unslice(.d)
}
\arguments{
\item{.d}{A data frame to slice or unslice.}

\item{.cols}{A character vector of column names or a numeric vector
of column positions. If \code{NULL}, the slicing attributes are
removed.}
}
\value{
A sliced or unsliced data frame.
}
\description{
\code{slice_rows()} is equivalent to dplyr's
\code{\link[dplyr:group_by]{dplyr::group_by()}} command but it takes a vector of
column names or positions instead of capturing column names with
special evaluation. \code{unslice()} removes the slicing
attributes.
}
\seealso{
\code{\link[=by_slice]{by_slice()}} and \code{\link[dplyr:group_by]{dplyr::group_by()}}
}