powered by
Sums each regions flows (from origin rows and destination columns) to obtain net migration sums.
sum_net(m, region = 1:dim(m)[1])
Matrix of origin-destination flows, where the first and second dimensions correspond to origin and destination respectively.
Integer value corresponding to the region that the net migration sum is desired. Will return sums for all regions by default.
Returns a numeric value of the sum of a single block.
block_sum, sum_od
block_sum
sum_od
# NOT RUN { m <- matrix(data = 1:16, nrow = 4, ncol = 4) sum_net(m) # }
Run the code above in your browser using DataLab