Skip to content

Commit

Permalink
✨ Initial commit for branch "dev_morgan_massey" (ndi v0.1.6.9013) (#30)
Browse files Browse the repository at this point in the history
*  `morgan_massey()` function that computes the Distance-Decay Isolation Index (_DPxx\*_) based on [Morgan (1983)](https://www.jstor.org/stable/20001935) and [Massey & Denton (1988)](https://doi.org/10.1093/sf/67.2.281)
  • Loading branch information
idblr authored Sep 2, 2024
1 parent a8f3c7e commit d84f01e
Show file tree
Hide file tree
Showing 56 changed files with 1,042 additions and 185 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: ndi
Title: Neighborhood Deprivation Indices
Version: 0.1.6.9012
Date: 2024-09-01
Version: 0.1.6.9013
Date: 2024-09-02
Authors@R:
c(person(given = "Ian D.",
family = "Buller",
Expand Down
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export(lieberson)
export(massey)
export(massey_duncan)
export(messer)
export(morgan_massey)
export(powell_wiley)
export(sudano)
export(theil)
Expand Down
7 changes: 4 additions & 3 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# ndi (development version)

## ndi v0.1.6.9012
## ndi v0.1.6.9013

### New Features

Expand All @@ -17,9 +17,10 @@
* Added `duncan_duncan()` function to compute the aspatial racial or ethnic Relative Centralization (*RCE*) based on [Duncan & Duncan (1955b)](https://doi.org/10.1086/221609) and [Massey & Denton (1988)](https://doi.org/10.1093/sf/67.2.281)
* Added `massey()` function to compute the aspatial racial or ethnic Absolute Clustering (*ACL*) based on [Massey & Denton (1988)](https://doi.org/10.1093/sf/67.2.281)
* Added `massey_duncan()` function to compute the aspatial racial or ethnic Absolute Concentration (*ACO*) based on [Massey & Denton (1988)](https://doi.org/10.1093/sf/67.2.281) and Duncan, Cuzzort, & Duncan (1961; LC:60007089)
* Added `morgan_massey()` function to compute the aspatial racial or ethnic Distance-Decay Isolation Index (_DPxx\*_) based on [Morgan (1983)](https://www.jstor.org/stable/20001935) and [Massey & Denton (1988)](https://doi.org/10.1093/sf/67.2.281)

#### New Function Capabilities
* Added `geo_large = 'place'` for census-designated places, `geo_large = 'cbsa'` for core-based statistical areas, `geo_large = 'csa'` for combined statistical areas, and `geo_large = 'metro'` for metropolitan divisions as the larger geographical unit in `atkinson()`, `bell()`, `bemanian_beyer()`, `denton()`, `denton_cuzzort()`, `duncan()`, `duncan_cuzzort()`, `duncan_duncan()`, `hoover()`, `james_taeuber()`, `lieberson()`, `massey()`, `massey_duncan()`, `sudano()`, `theil()`, and `white()`, `white_blau()` functions.
* Added `geo_large = 'place'` for census-designated places, `geo_large = 'cbsa'` for core-based statistical areas, `geo_large = 'csa'` for combined statistical areas, and `geo_large = 'metro'` for metropolitan divisions as the larger geographical unit in `atkinson()`, `bell()`, `bemanian_beyer()`, `denton()`, `denton_cuzzort()`, `duncan()`, `duncan_cuzzort()`, `duncan_duncan()`, `hoover()`, `james_taeuber()`, `lieberson()`, `massey()`, `massey_duncan()`, `morgan_massey()`, `sudano()`, `theil()`, and `white()`, `white_blau()` functions.
* Added census block group computation for `anthopolos()` by specifying `geo == 'cbg'` or `geo == 'block group'`
* Added `holder` argument to `atkinson()` function to toggle the computation with or without the Hölder mean. The function can now compute *A* without the Hölder mean. The default is `holder = FALSE`.
* Added `crs` argument to `anthopolos()`, `bravo()`, and `white_blau()` functions to provide spatial projection of the distance-based metrics
Expand All @@ -45,7 +46,7 @@
* Re-formatted code and documentation throughout for consistent readability
* Renamed 'race/ethnicity' or 'racial/ethnic' to 'race or ethnicity' or 'racial or ethnic' throughout documentation to use more modern, inclusive, and appropriate language
* Updated documentation about value range of *V* (White) from `{0 to 1}` to `{-Inf to Inf}`
* Added examples for `atkinson()`, `duncan_cuzzort()`, `duncan_duncan()`, `gini()`, `hoover()`, `james_taeuber()`, `lieberson()`, `massey()`, `massey_duncan()`, `theil()`, and `white_blau()` functions in vignettes and README
* Added examples for `atkinson()`, `duncan_cuzzort()`, `duncan_duncan()`, `gini()`, `hoover()`, `james_taeuber()`, `lieberson()`, `massey()`, `massey_duncan()`, `morgan_massey()`, `theil()`, and `white_blau()` functions in vignettes and README
* Added example for `holder` argument in `atkinson()` function in README
* Reordered the contents of 'ndi-package.R' thematically
* Reordered the README examples alphabetically
Expand Down
5 changes: 3 additions & 2 deletions R/anthopolos.R
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Racial Isolation Index of Black populations
#' ## of census tracts within Georgia, U.S.A., counties (2020)
#' # Racial Isolation Index (a measure of isolation)
#' ## of Black populations
#' ## in census tracts of Georgia, U.S.A. (2020)
#' anthopolos(
#' geo = 'tract',
#' state = 'GA',
Expand Down
10 changes: 6 additions & 4 deletions R/atkinson.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Atkinson Index (a measure of the evenness) of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Atkinson Index (a measure of the evenness)
#' ## of Black populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' atkinson(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand All @@ -80,8 +81,9 @@
#' subgroup = c('NHoLB', 'HoLB')
#' )
#'
#' # Atkinson Index of median household income
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Atkinson Index (a measure of the evenness)
#' ## of median household income
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' atkinson(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/bell.R
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Interaction of non-Hispanic Black vs. non-Hispanic white populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Interaction Index (a measure of exposure)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' bell(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/bemanian_beyer.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Local Exposure and Isolation of non-Hispanic Black vs. non-Hispanic white populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Local Exposure and Isolation
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' bemanian_beyer(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/bravo.R
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Educational Isolation Index of less than some college or associate's degree attainment
#' ## of census tracts within Georgia, U.S.A., counties (2020)
#' # Educational Isolation Index (a measure of exposure)
#' ## of less than some college or associate's degree attainment
#' ## in census tracts of Georgia, U.S.A. (2020)
#' bravo(
#' geo = 'tract',
#' state = 'GA',
Expand Down
5 changes: 3 additions & 2 deletions R/denton.R
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Index of spatial proximity of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Relative Clustering (a measure of clustering)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' denton(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/denton_cuzzort.R
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Index of spatial proximity of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Relative Concentration (a measure of concentration)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' denton_cuzzort(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
4 changes: 2 additions & 2 deletions R/duncan.R
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Dissimilarity Index (Duncan & Duncan)
#' # Dissimilarity Index (Duncan & Duncan; a measure of evenness)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' duncan(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/duncan_cuzzort.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Absolute Centralization of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Absolute Centralization (a measure of centralization)
#' ## of Black populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' duncan_cuzzort(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/duncan_duncan.R
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Relative Centralization of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Relative Centralization (a measure of centralization)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' duncan_duncan(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/gini.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Gini Index (a metric of unevenness) of Black populations
#' ## of census tracts within Georgia, U.S.A., counties (2020)
#' # Gini Index (a metric of evenness)
#' ## of Black populations
#' ## in census tracts of Georgia, U.S.A. (2020)
#' gini(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
3 changes: 2 additions & 1 deletion R/globals.R
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,7 @@ globalVariables(
'TotalPopE',
'n_1',
'n_2',
't_cs'
't_cs',
'DPxx_star'
)
)
5 changes: 3 additions & 2 deletions R/hoover.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Delta (a measure of concentration) of non-Hispanic Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Delta (a measure of concentration)
#' ## of non-Hispanic Black populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' hoover(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
4 changes: 2 additions & 2 deletions R/james_taeuber.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Dissimilarity Index (James & Taeuber)
#' # Dissimilarity Index (James & Taeuber; a measure of evenness)
#' ## of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' james_taeuber(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/lieberson.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Interaction of non-Hispanic Black vs. non-Hispanic white populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Interaction (a measure of exposure)
#' ## of non-Hispanic Black vs. non-Hispanic white populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' bell(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/massey.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Index of spatial proximity of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Absolute Clustering (a measure of clustering)
#' ## of Black populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' massey(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
5 changes: 3 additions & 2 deletions R/massey_duncan.R
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@
#' \dontrun{
#' # Wrapped in \dontrun{} because these examples require a Census API key.
#'
#' # Index of spatial proximity of Black populations
#' ## of census tracts within counties within Georgia, U.S.A., counties (2020)
#' # Absolute Concentration (a measure of concentration)
#' ## of Black populations
#' ## in census tracts within counties of Georgia, U.S.A. (2020)
#' massey_duncan(
#' geo_large = 'county',
#' geo_small = 'tract',
Expand Down
Loading

0 comments on commit d84f01e

Please sign in to comment.