pull1: Pull out a single element from a (list-) variable

Description Usage Arguments Value

View source: R/utilityFunctions.R

Description

dplyr::pull is a convenient way to pull out the values of a column from a data frame, but if you've got a long list column and just want to check one to make sure everything's working, printing the whole list can clutter up the console. pull1 just pulls out one.

Usage

1
pull1(.data, my_var, one_to_pull = 1)

Arguments

.data

a data frame

my_var

the unquoted name of the variable you want to pull out an element from

one_to_pull

if you don't want to pull the first element, set this to the row number of the one you want

Value

The one_to_pull-th element of the input variable


andrewGhazi/ghzutils documentation built on Nov. 30, 2020, 5:23 a.m.