Learn R Programming

bulkreadr (version 1.1.1)

pull_out: Extract or replace parts of an object

Description

pull_out() is similar to [. It acts on vectors, matrices, arrays and lists to extract or replace parts. It is pleasant to use with the magrittr (%>%) and base (|>) operators.

Arguments

Value

pull_out() will return an object of the same class as the input object.

Examples

Run this code

good_choice <- letters %>%
  pull_out(c(5, 2, 1, 4))

good_choice

iris %>%
  pull_out(, 1:4) %>%
  head()

Run the code above in your browser using DataLab