A demonstration of how to import complex spreadsheets with tidyxl and unpivotr.
The example spreadsheets are from the United Kingdom Department for Environment, Food & Rural Affairs collection Structure of the agricultural industry in England and the UK at June, which are "detailed annual statistics on the structure of the agricultural industry at 1 June in England and the UK".
Each spreadsheet file is in its own folder, along with an R script to import it
in a tidy fashion. Most of the files were originally .xls
or .ods
so were
converted to .xlsx
(for compatibility with tidyxl) using LibreOffice's
command-line utility.
libreoffice --convert-to xlsx */*