Using R in RapidMiner

z384zhanz384zhan MemberPosts:4Contributor I
edited November 2018 inHelp

I installed the Execute R script operator in RapidMIner. Everything works fine but I found the following code didn't work:

rm_main = function(dataset)
{
new_dataset =数据集(1 c(1、5))
return new_dataset
}

Basically all the operations using "[]" doesn't work properly. I understand this can be done by Select Attributes in RapidMIner, but is it my problem or such R syntax is not supported in RapidMIner?

Tagged:

Best Answer

  • z384zhanz384zhan MemberPosts:4Contributor I
    Solution Accepted

    Never mind. I passed a R data table instead of a data frame into the function. Although in R you can treat table as data frame but here you have to change it to an actual "data frame" using as.data.frame.matrix(dataset). Hope this is helpful to you guys.

    Sign InorRegisterto comment.