Closed ChristinaSchmidt1 closed 10 months ago
Denes suggested me to use simple caching with rappdirs (https://cran.r-project.org/web/packages/rappdirs/rappdirs.pdf). Basically, we access the user_chache_dir() and if there is a rds file with the KEGG_pathways already, we open it opposed to using KEGGRest to load from scratch.
I saved the .rds file in the cache directory of R. If the user already has file in this directory after using the function, it is not loaded again.
To make the run faster, we can cache the results similar how Denes did for OmnipathR: https://github.com/saezlab/OmnipathR/blob/master/R/cache.R
OR use: library(memoise)