0
votes

Hej, no matter what I try, I keep getting the error: file not recognised as 'CSV data files' file, reason: null, while loading a cvs file into Weka explorer. Any suggestions what could be wrong? I have been trying "correct" this type of errors Wrong number of values, Read 1, expected 2 Token[EOL], line 17 and after it stops giving those, the null one appears.

The file in question: file link

Thank you in advance!

1

1 Answers

0
votes

I've preprocessed the file with these shell commands.

# optional:
# The file uses "\r" characters (sometimes displayed as ^M) characters
# as line separator. Character "\n" is better.
# make it a unix-compliant csv file
# original file is saved into ~/Downloads/rezultati.csv.bak
perl -pi.bak -E "s/\r/\n/g" ~/Downloads/rezultati.csv 
# end optional 

# take first 240 lines, except the defective last line .
# I don't know what's wrong  with it. maybe it's "No newline at end of file"
# I'll just omit that single line starting with ID 243.
head -240 ~/Downloads/rezultati.csv > ~/Downloads/rezultati-240.csv

resultati-240.csv can be loaded into weka.