Calculates the depth of a list
depth(this, thisdepth = 1)
this | A list whose depth needs to be calculated |
---|---|
thisdepth | The default value if the list is flat |
An integer specifying the depth of a list
https://stackoverflow.com/a/13433689/1987629 (Function copied from)
#> [1] 3depth(1:5) # 1#> [1] 1#> [1] 4#> [1] 2