PolyMathOrg / DataFrame

DataFrame in Pharo - tabular data structures for data analysis
MIT License
74 stars 29 forks source link

Write to CSV without saving the column index #284

Closed olekscode closed 6 months ago

olekscode commented 6 months ago

(from this comment: https://github.com/PolyMathOrg/DataFrame/issues/215#issuecomment-1503599287)

we need to add a method that allows to save a DataFrame as a CSV file without the id.
Currently, the only method available is DataFrame>>#writeToCsv: but automatically adds an
empty column at the beginning with the internal id that was calculating.
We should be able to save without that id

We can create a new method called writeToCsv:withRowNames: Then method writeToCsv: shoud call it with the default parameter true

writeToCsv: aFileReference
    self writeToCsv: aFileReference withRowNames: true