traverse: Recursively traverse an object

View source: R/traverse.R

traverseR Documentation

Recursively traverse an object

Description

Recursively traverse an object

Usage

traverse(
  x,
  .f = list,
  .g = identity,
  .h = identity,
  base = function(.x) is_syntactic_literal(.x) || is_symbol(.x)
)

Arguments

x

The object to traverse

.f

A function for combining the recursed components

.g

A function applied to the object before recursion

.h

A function applied to the base case

base

The base case for the recursion


fabletools documentation built on Oct. 12, 2023, 1:07 a.m.