0

I am trying to run Weka AODE class in R using RWeka. The following code returns an error.

library("RWeka")
NB <- make_Weka_classifier("weka/classifiers/bayes/AODE")
classifier <- NB(Species ~ ., data = iris)

And I get this:

Error in .jnew("weka/core/Attribute", attname[i], .jcast(levels, "java/util/List")) : 
java.lang.NoSuchMethodError: <init>

I have verified that RWeka/java/RWeka.jar contains the AODE.class file.

when trying to run the naive bayes example in the RWeka manual in cran I get the same error.

Any ideas why I get this error?

z-star
  • 680
  • 5
  • 6
  • are you using the correct java version? i.e. 32 bits jave with 32 bits R or 64 bits jave with 64 bits R. Default of java install is 32 bits. – phiver Oct 12 '15 at 08:35
  • My java: OpenJDK 64-Bit. My R returned 8 on .Machine$sizeof.pointer, so I guess is 64 as well. – z-star Oct 12 '15 at 09:00

0 Answers0