multi_comp: Multiplicative component description of origin-destination...

View source: R/multi_comp.R

multi_compR Documentation

Multiplicative component description of origin-destination migration flow tables

Description

Multiplicative component descriptions of *n*-dimension flow tables based on total reference coding system.

Usage

multi_comp(m)

Arguments

m

matrix or array of migration flows

Value

matrix or array of multiplicative components of 'm'. When output is an array the total for each table of origin-destination flows is used.

References

Rogers, A., Willekens, F., Little, J., & Raymer, J. (2002). Describing migration spatial structure. Papers in Regional Science, 81(1), 29–48. https://doi.org/10.1007/s101100100090

Raymer, J., Bonaguidi, A., & Valentini, A. (2006). Describing and projecting the age and spatial structures of interregional migration in Italy. Population, Space and Place, 12(5), 371–388. https://doi.org/10.1002/psp.414

Examples

r <- LETTERS[1:4]
m0 <- matrix(data = c(0, 100, 30, 70, 50, 0, 45, 5, 60, 35, 0, 40, 20, 25, 20, 0), 
             nrow = 4, ncol = 4, byrow = TRUE, dimnames = list(orig = r, dest = r))
addmargins(m0)
multi_comp(m = m0)

# data frame
library(dplyr)
italy_area %>%
  filter(year == 2000) %>%
  multi_comp() %>%
  round(digits = 3)

migest documentation built on Nov. 18, 2023, 9:06 a.m.