| esp_clear_cache | R Documentation |
Use this function with caution. It clears your cached data and configuration, specifically:
Deletes the mapSpain configuration directory
(tools::R_user_dir("mapSpain", "config")).
Deletes the cache_dir directory and its contents.
Clears the value stored in Sys.getenv("MAPSPAIN_CACHE_DIR").
esp_clear_cache(config = FALSE, cached_data = TRUE, verbose = FALSE)
config |
logical. If |
cached_data |
logical. If |
verbose |
logical. If |
This is an aggressive function intended to reset your installation as if you had never installed or used mapSpain.
Invisible. This function is called for its side effects.
tools::R_user_dir()
Other cache utilities:
esp_set_cache_dir()
# Don't run this! It would modify your current state
## Not run:
my_cache <- esp_detect_cache_dir()
# Set an example cache
ex <- file.path(tempdir(), "example", "cache")
esp_set_cache_dir(ex, verbose = FALSE)
# Restore initial cache
esp_clear_cache(verbose = TRUE)
esp_set_cache_dir(my_cache)
identical(my_cache, esp_detect_cache_dir())
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.