Releases: pdil/usmapdata
Releases · pdil/usmapdata
usmapdata 1.0.0
New Features
- Puerto Rico has been added!
- Finally, after years of procrastinating, Puerto Rico has finally been added to the map, see Issue #48.
- All included map files have been retroactively updated to include Puerto Rico, so any valid value of
data_yearwill include Puerto Rico if desired. us_map()andfips_data()both return Puerto Rico in their data sets and it can be included or excluded just like any state (using FIPS, full name, abbreviation, etc.).- Special thanks @dcaud who started this work years ago.
Enhancements
includenow takes precedence overexcludeinus_map().- Any items that are in both the
includeandexcludevectors will be included.
- Any items that are in both the
Removed
- The
as_sfparameter has been completely removed fromus_map(),centroid_labels(), andfips_data().- It was no longer used by
usmapnor did it have any effect if set. - Any existing code that sets it can safely delete it from
usmapdatafunction calls.
- It was no longer used by
Full Changelog: v0.6.0...v1.0.0
usmapdata 0.6.0
- Change output of
us_map()andcentroid_labels()to data frame instead of tibble.- If
tibbleformat is required usetibble::as_tibble()on the output.
- If
Full Changelog: v0.5.0...v0.6.0
usmapdata 0.5.0
- Add 2024 shape files.
Full Changelog: v0.4.0...v0.5.0
usmapdata 0.4.0
New Features
- Add
data_yearparameter tous_map(), see Issue #34.- Allows user to select the year for which to plot US map.
- This will allow the user to match the map that is provided to the data they are using.
- To start with, 2021, 2022, and 2023 maps are included.
- Going forward, each year will be added to the package and previous years can be accessed with this parameter.
- If the value provided via
data_yearis not available, the package will select the next year for which data exists.- For example, if data sets 2022 and 2023 are available and the user calls
us_map(data_year = 2019), 2022 will be used. - A warning is presented when this occurs to alert the user.
- For example, if data sets 2022 and 2023 are available and the user calls
- Further reading on the impetus for this change: major changes made to Connecticut counties in 2023.
- The old Connecticut counties are available in the 2021 data, 2022 and forward use the new planning regions.
Improvements
- Improve python script and GitHub Actions workflow that download and process map shapefiles to be more flexible and support new
data_yearfeature listed above. centroid_labels()now accepts"state"and"county"as inputs for theregionsparameter likeus_map()andfips_data().- Update package author email.
Full Changelog: v0.3.0...v0.4.0
usmapdata 0.3.0
- Update map data to use 2023 shape files.
Full Changelog: v0.2.2...v0.3.0
usmapdata 0.2.2
Improvements
- Improve language in
DESCRIPTIONand minor documentation, see Issue #19.
Bug Fixes
alaska_bbox()andhawaii_bbox()now output correctsftype (sfc polygon).
Full Changelog: v0.2.1...v0.2.2
usmapdata 0.2.1
This update continues the sf migration by setting the as_sf parameter to default to the behavior of TRUE. This parameter no longer has any effect, as explained below. The next phase will involve updating usmap to no longer make use of this parameter, in which case it can be completely removed.
Removed
- The
as_sfparameter is now deprecated and no longer has any effect.- As part of this removal, the default behavior for
us_map(),centroid_labels(), andfips_data()is equivalent toas_sf = TRUEwhich is to return their data as ansfobject (see0.2.0release notes for more details). - This parameter will be completely removed in a future version but continues to exist for compatibility reasons.
- As part of this removal, the default behavior for
- Legacy
.csvfiles containing mapping and FIPS data have been removed, greatly reducing package size.
Full Changelog: v0.2.0...v0.2.1
usmapdata 0.2.0
Improvements
- Update map data to use 2022 shape files.
- Begin process of upgrading map data to use GeoPackage files instead of csv.
- Previously the files were created using now-retired packages
rgdal,rgeos, andmaptools. - The new files can be accessed by passing
as_sf = TRUEto theus_map()andfips_data()functions. - Once the upgrade is complete, this parameter will be removed and the new functionality will be the default.
- The new map files are smaller in size while maintaining the same resolution.
- The format of the data also allows for easier manipulation in the future using the
sfpackage.
- Previously the files were created using now-retired packages
- Add scripts to perform automated map data updates, see Issue #5.
- The scripts will check for new shapefiles from the US Census Bureau twice a year and automatically update the data.
- The scripts can also be run manually as needed.
- Once data is updated a new
usmapdatarelease will be created.
Full Changelog: v0.1.2...v0.2.0
usmapdata 0.1.2
- Add
fips_datafunction to load raw FIPS data from included csv files.fips_data(),fips_data("state"), orfips_data("states")load state FIPS codesfips_data("county")orfips_data("counties")load county FIPS codes
Full Changelog: v0.1.1...v0.1.2
usmapdata 0.1.1
- Update package author email and website.
Full Changelog: v0.1.0...v0.1.1