I am trying to parse a CSV file, ideally using weka.core.converters.CSVLoader. However the file I have is not a valid UTF-8 file. It is mostly a UTF-8 file but some of the f
Scala's Codec has a decoder field which returns a java.nio.charset.CharsetDecoder:
java.nio.charset.CharsetDecoder
val decoder = Codec.UTF8.decoder.onMalformedInput(CodingErrorAction.IGNORE) Source.fromFile(filename)(decoder).getLines().toList