Using the %>% pipe, and dot (.) notation
问题 When using map on a nested data_frame, I do not understand why the latter two version give an error, how should I use the dot ( . )? library(tidyverse) # dummy data df <- tibble(id = rep(1:10, each = 10), val = runif(100)) df <- nest(df, -id) # works as expected map(df$data, min) df %>% .$data %>% map(., min) # gives an error df %>% map(.$data, min) # Error: Don\'t know how to index with object of type list at level 1 df %>% map(data, min) 回答1: The problem isn't map , but rather how the %>%