get_path_list: Get the paths of branches in a list

View source: R/00-utils.R

get_path_listR Documentation

Get the paths of branches in a list

Description

Function that recursively go through a list object and store in a tibble the path of each element in the list. The paths can be after that edited and accessed using parceval() for example.

Usage

get_path_list(list_obj, .map_list = NULL)

Arguments

list_obj

R list object to be evaluated

.map_list

non usable parameter. This parameter is only there to ensure recursivity. Any modification of this object returns NULL

Value

A tibble containing all the paths of each element of the list and the class of each leaf (can be a list, or R objects).

See Also

parceval()

Examples

{

library(dplyr)
get_path_list(
  list(
    tibble = iris,
    list = list(t1 = mtcars, t2 = tibble(iris)),
    char = "foo"))

}


fabR documentation built on May 29, 2024, 2:58 a.m.