2013-03-17 52 views
1

我有一些数据,我正在处理它并将其转换为它生成的方式。 ARFF文件如下:无法确定为arff(原因:java.io.IOException:行过早结束,读取令牌[EOL],行1182

............ 

@attribute murdered_to numeric 
@attribute envy.although_it numeric 
@attribute vampire_that numeric 
@attribute list_without numeric 
@attribute award_at numeric 
@attribute @% numeric 
@attribute the_addict numeric 
@attribute the_drag numeric 
@attribute card_against numeric 
@attribute communications_mainly numeric 
@attribute clue_for numeric 
@attribute justified.a numeric 
@attribute superb_learning numeric 
@attribute ford_escape numeric 
@attribute a_life-changing numeric 
. 
. 
. 

这仅仅是一个属性列表中的一部分,我需要打开在WEKA的ARFF文件,但将作为主题提到的错误错误指向到行:

@attribute the_addict numeric 

我无法在引发错误的文件中找到错误

+0

http://www.cs.waikato.ac.nz/ml/weka/arff.html – etov 2013-03-17 21:13:55

回答

3

我敢肯定的错误是在你报

@attribute @% numeric 

你的属性的名称是无效的一个前行,它必须以字母字符开始,作为ARFF文件中规定指出在etov

为@attribute声明的格式为:

@attribute <attribute-name> <datatype> 

其中必须以字母字符开头。如果名称中包含空格,则必须引用整个名称。