Skip to content

Bad @DATA instance format, cannot handle data instance end with comma #101

@Anjin-Liu

Description

@Anjin-Liu

Hi,
Happy new year!

I recently used weka to generate some .arff files.
The files looks like

@relation 'SEA'

@Attribute attrib1 numeric
@Attribute attrib2 numeric
@Attribute attrib3 numeric
@Attribute class {groupA,groupB}

@DaTa

7.30967787376657,2.4053641567148585,6.374174253501082,groupB,
1.1700660880722513,7.815346320453048,2.5277616657598587,groupB,
9.84841540199809,8.791825178724801,9.412491794821143,groupB,
3.1293596519376554,3.6797575871052812,7.051747444754559,groupA,

which has a comma at the end of each row.
These files can be read by weka correctly, but cannot be loaded by liac-arff.
liac-arff will report
"Bad @DaTa instance format in line 10: 7.30967787376657,2.4053641567148585,6.374174253501082,groupB,"

after removing the comma, it works fine.

So, I think this might be an inconsistency with weka and submit this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions