From 6bb3072a9b67f3dfc7e0388c67145bc7b5e8c4af Mon Sep 17 00:00:00 2001
From: hadley ArgumentsExamples
as_mapper(\(x) x + 1)
#> \(x) x + 1
-#> <environment: 0x5561a3807fb8>
+#> <environment: 0x55f466744ac8>
as_mapper(1)
#> function (x, ...)
#> pluck_raw(x, list(1), .default = NULL)
-#> <environment: 0x5561a2f6a718>
+#> <environment: 0x55f470129938>
as_mapper(c("a", "b", "c"))
#> function (x, ...)
#> pluck_raw(x, list("a", "b", "c"), .default = NULL)
-#> <environment: 0x5561a8b5b180>
+#> <environment: 0x55f4703d59f8>
# Equivalent to function(x) x[["a"]][["b"]][["c"]]
as_mapper(list(1, "a", 2))
#> function (x, ...)
#> pluck_raw(x, list(1, "a", 2), .default = NULL)
-#> <environment: 0x5561ab26b528>
+#> <environment: 0x55f46fb08068>
# Equivalent to function(x) x[[1]][["a"]][[2]]
as_mapper(list(1, attr_getter("a")))
#> function (x, ...)
#> pluck_raw(x, list(1, function (x)
#> attr(x, attr, exact = TRUE)), .default = NULL)
-#> <environment: 0x5561aac9af88>
+#> <environment: 0x55f46db8c250>
# Equivalent to function(x) attr(x[[1]], "a")
as_mapper(c("a", "b", "c"), .default = NA)
#> function (x, ...)
#> pluck_raw(x, list("a", "b", "c"), .default = NA)
-#> <environment: 0x5561a89a2028>
+#> <environment: 0x55f46dad8e98>
Other modify variants:
-modify_tree()
,
-modify()
modify()
,
+modify_tree()
Other map variants:
imap()
,
lmap()
,
+map()
,
map2()
,
map_depth()
,
-map()
,
modify()
,
pmap()
Other map variants:
imap()
,
lmap()
,
+map()
,
map2()
,
map_depth()
,
map_if()
,
-map()
,
pmap()
Other modify variants:
map_depth()
,
diff --git a/dev/reference/partial.html b/dev/reference/partial.html
index 3b874c18..a49f8697 100644
--- a/dev/reference/partial.html
+++ b/dev/reference/partial.html
@@ -172,7 +172,7 @@
Other map variants:
imap()
,
lmap()
,
+map()
,
map2()
,
map_depth()
,
map_if()
,
-map()
,
modify()