【问题标题】:Unable to determine as arff (Reason: java.io.IOException: premature end of line, read Token [EOL], line 1182无法确定为 arff(原因:java.io.IOException:过早结束行,读取令牌 [EOL],第 1182 行
【发布时间】:2013-03-06 00:48:15
【问题描述】:

我有一些数据,我正在处理它并将其转换为生成 .arff 文件的方式,如下所示:

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

@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

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

【问题讨论】:

标签: weka ioexception arff


【解决方案1】:

我很确定错误在你引用的那一行之前

@attribute @% numeric

您的属性名称无效,它必须以字母字符开头,如 etov 所指向的 ARFF 文档中所指定。

@attribute 语句的格式为:

@attribute <attribute-name> <datatype>

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

【讨论】:

    猜你喜欢
    • 2014-01-07
    • 2016-12-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多