Skip to contents

Recursively removes unnecessary lists ("lame lists") from a list. A lame list is a unnamed list containing a single list object (see lame_list).

Usage

clean_list(l)

Arguments

l

A list.

Value

a list.

Examples

if (FALSE) {
clean_list(list(list(1:10)))
clean_list(list(A = list(1:10)))
clean_list(list(list(1:10), list(11:20)))
}