Github user shivaram commented on a diff in the pull request:
https://github.com/apache/spark/pull/10123#discussion_r46637044
--- Diff: R/pkg/R/RDD.R ---
@@ -306,17 +306,26 @@ setMethod("checkpoint",
#'\dontrun{
#' sc <- sparkR.init()
#' rdd <- parallelize(sc, 1:10, 2L)
-#' numPartitions(rdd) # 2L
+#' getNumPartitions(rdd) # 2L
#'}
-#' @rdname numPartitions
+#' @rdname getNumPartitions
+#' @aliases getNumPartitions,RDD-method
+#' @noRd
+setMethod("getNumPartitions",
+ signature(x = "RDD"),
+ function(x) {
+ callJMethod(getJRDD(x), "getNumPartitions")
+ })
+
+#' numPartitions is the same as getNumPartitions
--- End diff --
Could you add a note that this is deprecated here ?
Also this is the title of the document, so its better to have this be
something like `Gets the number of partitions of an RDD` cc @felixcheung
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]