classifying data from an ARFF in weka
I have an ARFF that i've loaded into the weka explorer. I'm quite new to weka but to my understanding the arff i have should be working however none of the classifiers appear to work with it?
@RELATION wordfrequency
@ATTRIBUTE word string
@ATTRIBUTE frequency numeric
@DATA
allah,71
ye,65
day,46
lord,21
truth,20
say,20
and,20
the,19
return,19
it,19
Is there something i've missed addi开发者_StackOverflow中文版ng to the arff file? Any help is appreciated. Thanks.
you want to classify and where is the attribute for class? if you create an attribute class {c1,c2}. and filter your attributes in weka chose filter->unsupervised->attribute->Stringtovector
and apply after this you can classify , it work with the naive bayes and other classifiers.
@RELATION wordfrequency
@ATTRIBUTE word string
@ATTRIBUTE frequency numeric
@ATTRIBUTE class {c1,c2}
@DATA
allah,71,c1
ye,65,c2
day,46,c1
lord,21,c2
truth,20,c1
say,20,c2
精彩评论