Github user felixcheung commented on a diff in the pull request:
https://github.com/apache/spark/pull/21645#discussion_r201574237
--- Diff: R/pkg/R/functions.R ---
@@ -3120,6 +3147,24 @@ setMethod("arrays_overlap",
column(jc)
})
+#' @details
+#' \code{arrays_zip}: Returns a merged array of structs in which the N-th
struct contains all N-th
+#' values of input arrays.
+#'
+#' @rdname column_collection_functions
+#' @aliases arrays_zip arrays_zip,Column-method
+#' @note arrays_zip since 2.4.0
+setMethod("arrays_zip",
+ signature(x = "Column"),
+ function(x, ...) {
+ jcols <- lapply(list(x, ...), function(x) {
+ stopifnot(class(x) == "Column")
+ x@jc
--- End diff --
nit: probably clearer to name the x in function(x) as something else
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]