srowen commented on a change in pull request #24458: [SPARK-27540][MLlib] Add 
'meanAveragePrecision_at_k' metric to RankingMetrics
URL: https://github.com/apache/spark/pull/24458#discussion_r278596815
 
 

 ##########
 File path: 
mllib/src/main/scala/org/apache/spark/mllib/evaluation/RankingMetrics.scala
 ##########
 @@ -92,6 +92,56 @@ class RankingMetrics[T: ClassTag](predictionAndLabels: 
RDD[(Array[T], Array[T])]
     }.mean()
   }
 
+  /**
+   * Returns the mean average precision (MAP) at ranking position k of all the 
queries.
 
 Review comment:
   It's kind of "average precision up to position k" rather than at? but I 
understand its conventional to call this average precision at k. Is there 
anything we can link to to further explain?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to