我正在使用RStudio连接cassandraDB表数据并对其进行关联规则建模。我想在关联规则模型中使用这些表数据所以我想将此表转换为逗号分隔!
这里是获取表列和数据的代码:
> rddSelect <- select(rdd, customersegment, productcategory, region)
> typeof(rddSelect)
[1] "list"
> rddSelect
# Source: lazy query [?? x 3]
# Database: spark_connection
customersegment productcategory region
<chr> <chr> <chr>
1 Consumer Furniture Quebec
2 Corporate Office Supplies Prarie
3 Corporate Office Supplies Prarie
4 Corporate Office Supplies West
5 Home Office Office Supplies West
6 Consumer Office Supplies Quebec
7 Home Office Furniture Prarie
8 Small Business Office Supplies Quebec
9 Consumer Technology Atlantic
10 Home Office Technology Prarie
# ... with more rows
> rddSelectDF <- data.frame(rddSelect)
2条答案
按热度按时间mfpqipee1#
你是说这个吗?
更改文件夹的名称
gfttwv5a2#
你是说像这样的东西吗