Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use (flat) ODS spreadsheet format #15

Open
mayeulk opened this issue Nov 10, 2023 · 0 comments
Open

Use (flat) ODS spreadsheet format #15

mayeulk opened this issue Nov 10, 2023 · 0 comments

Comments

@mayeulk
Copy link

mayeulk commented Nov 10, 2023

I would suggest to use the flat ODS spreadsheet format. This can be used in addition to .csv or .xlsx.
ODS is the OpenDocument Spreadsheet format of LibreOffice Calc; in short, .ods files are zipped XML files.
Flat ODS is the same standard; except the "compression" algorithm is flat: meaning, uncompressed.

Flat ODS is more convenient than CSV: it opens right away in a spreadsheet software; column widht and types are preserved, as well as formatting...
Flat ODS is more convenient than XLSX: the result is readable by human, it is a 100% opensource technology.
Flat ODS is more convenient than ODS: being plain text, git knows how to make diffs of them; see a sample here; this is why LibreOffice created the flat format; see "LibreOffice and Version control".

Flat ODS files can be named .fods or .ods; they will be opened by Calc and Excel.

readODS::write_fods() supports writing in flat ods.

Based on code in #14, below is a sample code to write a flat ODS file:

readODS::write_fods(spdx_licenses_2_df, 
                    path = "spdx_licenses.fods",
                    row_names = FALSE # the default anyway
                    )

Another advantage of write_fods (and of write_ods) is the support of sheets within a single spreadsheet document.
This would allow, for instance, to store the content of the README in a additional sheet, within the same document.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant