You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to use the purrr and xlsx packages together to read multiple password-protected .xlsx files in a folder into a nested data frame. Each file has multiple sheets. I plan to:
List and store the file names in a "file" column.
Use purrr::map_chr() and xlsx::getSheets() to get the names of the sheets in each file in a "sheets" column.
Use a nested purrr::map() and purrr::map_dfr() to apply xlsx::read.xlsx() to every cell in the "file" column and every cell in the "sheets" column to read all sheets in a file and row-bind them into a data frame into a "data" column.
Somehow this code only ran once. When I tried to add the names() line to extract the list names (the sheet names) from the Java objects in the "sheets" column, I encountered the following error:
Error in ._jobjRef_dollar(x[["jobj"]], name) :
no field, method or inner class called 'use_cli_format'
The Traceback seemed to suggest that there was some overhead limit exceedance error:
Even if I removed the newly added names() line didn't help. I had to restart the R session to be able to rerun the code.
I also had this problem before with xlsx::read.xlsx(), when I was experimenting with my code. Once the above error occurred, even previously working code ran into this problem. Again, I had to restart the R session to be able to rerun the code.
Was it just me doing something wrong?
The text was updated successfully, but these errors were encountered:
I thought we had some docs on this, but apparently not. You have to modify the setup for the JVM before it is started (i.e. before you load any packages, because many packages will start the JVM).
I tried to use the purrr and xlsx packages together to read multiple password-protected .xlsx files in a folder into a nested data frame. Each file has multiple sheets. I plan to:
purrr::map_chr()
andxlsx::getSheets()
to get the names of the sheets in each file in a "sheets" column.purrr::map()
andpurrr::map_dfr()
to applyxlsx::read.xlsx()
to every cell in the "file" column and every cell in the "sheets" column to read all sheets in a file and row-bind them into a data frame into a "data" column.My code is as follows:
Somehow this code only ran once. When I tried to add the
names()
line to extract the list names (the sheet names) from the Java objects in the "sheets" column, I encountered the following error:The Traceback seemed to suggest that there was some overhead limit exceedance error:
Even if I removed the newly added
names()
line didn't help. I had to restart the R session to be able to rerun the code.I also had this problem before with
xlsx::read.xlsx()
, when I was experimenting with my code. Once the above error occurred, even previously working code ran into this problem. Again, I had to restart the R session to be able to rerun the code.Was it just me doing something wrong?
The text was updated successfully, but these errors were encountered: