hasIn: Check for values in nested named lists

Description Usage Arguments Value Examples

Description

Check for values in nested named lists

Usage

1
hasIn(named_list, listkeys)

Arguments

named_list

a named list

listkeys

vector of character strings, the nested names of the lists

Value

whether a non-NULL value exists at the path

Examples

1
2
   data = list("regions"=list("frontal"=list("thickness"=2.3, "area"=2345)));
   hasIn(data, c("regions", "nosuchregion"));   # FALSE

fsbrain documentation built on Sept. 16, 2021, 5:07 p.m.