本文簡要介紹
pyspark.RDD.max
的用法。用法:
RDD.max(key=None)
在這個 RDD 中找到最大的項目。
- key:函數,可選
用於生成比較 key 的函數
參數:
例子:
>>> rdd = sc.parallelize([1.0, 5.0, 43.0, 10.0]) >>> rdd.max() 43.0 >>> rdd.max(key=str) 5.0
相關用法
- Python pyspark RDD.mapPartitionsWithIndex用法及代碼示例
- Python pyspark RDD.map用法及代碼示例
- Python pyspark RDD.mapPartitionsWithSplit用法及代碼示例
- Python pyspark RDD.mapValues用法及代碼示例
- Python pyspark RDD.mapPartitions用法及代碼示例
- Python pyspark RDD.meanApprox用法及代碼示例
- Python pyspark RDD.min用法及代碼示例
- Python pyspark RDD.mean用法及代碼示例
- Python pyspark RDD.saveAsTextFile用法及代碼示例
- Python pyspark RDD.keyBy用法及代碼示例
- Python pyspark RDD.sumApprox用法及代碼示例
- Python pyspark RDD.lookup用法及代碼示例
- Python pyspark RDD.zipWithIndex用法及代碼示例
- Python pyspark RDD.sampleByKey用法及代碼示例
- Python pyspark RDD.coalesce用法及代碼示例
- Python pyspark RDD.subtract用法及代碼示例
- Python pyspark RDD.count用法及代碼示例
- Python pyspark RDD.groupWith用法及代碼示例
- Python pyspark RDD.distinct用法及代碼示例
- Python pyspark RDD.treeAggregate用法及代碼示例
- Python pyspark RDD.foreachPartition用法及代碼示例
- Python pyspark RDD.zipWithUniqueId用法及代碼示例
- Python pyspark RDD.sortByKey用法及代碼示例
- Python pyspark RDD.takeOrdered用法及代碼示例
- Python pyspark RDD.collectAsMap用法及代碼示例
注:本文由純淨天空篩選整理自spark.apache.org大神的英文原創作品 pyspark.RDD.max。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。