lengths: Backport of lengths for R < 3.2.0

View source: R/lengths.R

lengthsR Documentation

Backport of lengths for R < 3.2.0

Description

See the original description in base::lengths.

Usage

lengths(x, use.names = TRUE)

Examples

# get function from namespace instead of possibly getting
# implementation shipped with recent R versions:
bp_lengths = getFromNamespace("lengths", "backports")

bp_lengths(list(1:3, 2))

mllg/backports documentation built on Aug. 12, 2024, 12:31 p.m.