Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

tigris_cache_dir

Set the cache directory to store shapefiles with tigris


Description

By default, tigris uses the rappdirs package to determine a suitable location to store shapefiles on the user's computer. However, it is possible that the user would want to store shapefiles in a custom location. This function allows users to set the cache directory, and stores the result in the user's .Renviron so that tigris will remember the location.

Windows users: please note that you'll need to use double-backslashes or forward slashes when specifying your cache directory's path in R.

Usage

tigris_cache_dir(path)

Arguments

path

The full path to the desired cache directory

Examples

## Not run: 
# Set the cache directory
tigris_cache_dir('PATH TO MY NEW CACHE DIRECTORY')

# Check to see if it has been set correctly
Sys.getenv('TIGRIS_CACHE_DIR')

## End(Not run)

tigris

Load Census TIGER/Line Shapefiles

v1.0
MIT + file LICENSE
Authors
Kyle Walker [aut, cre], Bob Rudis [ctb]
Initial release
2020-07-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.