如何使用Python PySpark在zeppelin中创建数据帧?

2024-05-08 22:14:20 发布

您现在位置:Python中文网/ 问答频道 /正文

Bicycletheft_raw_data = Crime_data.filter(lambda x: 'Bicycle theft' in x)
Bicycletheft_raw_data.collect()
print Bicycletheft_raw_data.count()



df1 = sqlCtx.createDataFrame(BicycleTheft_raw_data , ['CrimeID','Month','Reportedby','Fallswithin','Longitude', 'Latitude','Location','LSOAcode','LSOAname','Crimetype','Lastoutcomecategory']) 

Py4JJavaError:调用o742.applySchemaToPythonRDD时出错


Tags: lambdaindatarawcountfiltercollectdf1

热门问题