Post by Les 5 en Orwant to convert a database file from .arff to .csv on the
terminal since I use a mac OX. Any clue?
As others have mentioned, some sample data would be most helpful.
My initial reaction based on my searches for .arff format
information suggest that it's a bad idea to try it with sed unless
you have tight control over the input file. The .arff docs I read
suggest that it's possible to have things like missing fields
("sparse records"), and that there's additional metadata that might
be stored in the header.
I'd likely start with [1] since I'm a Python programmer (there might
be something similar if you're a Perl coder), using the stdlib "csv"
module to create output instead of the SQL Alchemy. With some
sample data to play with, I'd even be willing to take a crack at
tweaking that Python code to spit out CSV.
-tkc
[1]
http://code.activestate.com/recipes/440533/