## Here we write a COIN to Excel, but this is done to a temporary directory
## to avoid "polluting" the working directory when running automatic tests.
## In a real case, set fname to a directory of your choice.
# build example coin up to data treatment step
coin <- build_example_coin(up_to = "Treat")
# write to Excel in temporary directory
export_to_excel(coin, fname = paste0(tempdir(), "\\ASEM_results.xlsx"))
# spreadsheet is at:
print(paste0(tempdir(), "\\ASEM_results.xlsx"))
# now delete temporary file to keep things tidy in testing
unlink(paste0(tempdir(),"\\ASEM_results.xlsx"))
Run the code above in your browser using DataLab