Convert Schema JSON-LD into tabular formats?
cboettig opened this issue · 3 comments
Currently we have some nice functions (write_spice()
) to go from tables -> json-ld. Seems like it would be handy to be able to easily reverse this process as well (e.g. someone gives you a bunch schema.org JSON-LD and you want it as tables where you can filter by geographic coverage and do automated unit conversions based on the measuredVariable
metadata etc).
What would such a function be called? read_spice()
? What would the return object be? (i.e. a list of data.frames
? .csv
files on disk? Something else?
This would be great! read_spice()
makes sense to me as json-ld --> csv since write_spice()
does the opposite (csv --> json-ld).
Maybe a separate get_spice()
function could load in the csvs as data frames?
I am never one to willingly miss an opportunity to push strained metaphors to their logical breaking points, but perhaps despice
/unspice
? Maybe then we could rename create_spice
to spice()
? Not that you can really despice things cooking.
I am all for exaggerated metaphors! Also a good chance for us to think carefully about our namespace — eg we have create_spice which really creates spreadsheet templates, and write_spice which turns those templates into JSON —kinda confusing. If the spice is the JSONLD form, than perhaps the templates are more like salt shakers?