Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

pyspark correlation between multiple columns

df1 = sc.parallelize([(0.0, 1.0), (1.0, 0.0)]).toDF(["x", "y"])
df1.stat.corr("x", "y")
# -1.0
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #pyspark #correlation #multiple #columns
ADD COMMENT
Topic
Name
9+8 =