You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Hyukjin Kwon (Jira)" <ji...@apache.org> on 2021/02/08 13:53:00 UTC
[jira] [Updated] (SPARK-34275) Replaces filter and size with count
[ https://issues.apache.org/jira/browse/SPARK-34275?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hyukjin Kwon updated SPARK-34275:
---------------------------------
Fix Version/s: 3.1.1
> Replaces filter and size with count
> -----------------------------------
>
> Key: SPARK-34275
> URL: https://issues.apache.org/jira/browse/SPARK-34275
> Project: Spark
> Issue Type: Improvement
> Components: ML, Spark Core, SQL
> Affects Versions: 3.2.0
> Reporter: Yang Jie
> Assignee: Yang Jie
> Priority: Minor
> Fix For: 2.4.8, 3.0.2, 3.2.0, 3.1.1, 3.1.2
>
>
> Use {{count}} to simplify {{find + size(or length) operation}}, it's semantically consistent, but looks simpler.
> *Before*
> {code:java}
> seq.filter(p).size{code}
> *After*
> {code:java}
> seq.count(p){code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org