BUG: adjust quotechar in CSV depending on output