Github user mengxr commented on a diff in the pull request:
https://github.com/apache/spark/pull/1710#discussion_r15681269
--- Diff: mllib/src/main/scala/org/apache/spark/mllib/stat/Statistics.scala
---
@@ -55,20 +55,24 @@ object Statistics {
/**
* Compute the Pearson correlation for the input RDDs.
- * Columns with 0 covariance produce NaN entries in the correlation
matrix.
+ * Returns NaN if either vector has 0 variance.
+ *
+ * Note: the two input RDDs need to have the same number of partitions.
--- End diff --
have the *same number of partitions* and the *same number of elements in
each partition*
---
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.
---