When working with nested tables within a table, if I wanted to pull one out, I would typically do something like the following in tidyverse:
my_tibble %>% slice(111) %>% pull(nested_column) %>% .[]
That last element in the pipeline is neccessary because otherwise my item is in a one element-long list and I want the object out from the list.
unlist doesn't work because it flattens out the data structure (often a tibble) within the nested column.
Now the problem is that if I convert this to a native pipe pipeline,
|> .[] produces the following error:
Error: function '[[' not supported in RHS call of a pipe
My shortcut is to create a function like
first <- function(x) x.[], but surely there is already a native way to do this.