Skip to content

Commit 1c0bc47

Browse files
committed
cran 2.0.5
1 parent 1d596ea commit 1c0bc47

File tree

4 files changed

+36
-6
lines changed

4 files changed

+36
-6
lines changed

DESCRIPTION

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
Package: migest
22
Type: Package
3-
Title: Tools for estimating, measuring and working with migration data.
3+
Title: Tools for estimating, measuring and working with migration data
44
Version: 2.0.5
55
Authors@R: c(person(c("Guy", "J."), "Abel", role = c("aut", "cre"),
66
email = "[email protected]",
77
comment = c(ORCID = "0000-0002-4893-5687")))
88
Maintainer: Guy J. Abel <[email protected]>
9-
Description: Tools for estimating, measuring and working with migration data.
9+
Description: Provides tools for estimating, measuring, and analyzing migration data. Designed to assist researchers and analysts in working effectively with migration data.
1010
URL: http://guyabel.github.io/migest/
1111
BugReports: https://github.com/guyabel/migest/issues
1212
License: GPL-3

NAMESPACE

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ export(sum_net)
4242
export(sum_od)
4343
export(sum_region)
4444
export(sum_unilat)
45+
export(sum_unilateral)
4546
import(utils)
4647
importFrom(CVXR,Minimize)
4748
importFrom(CVXR,Problem)

R/sum_region.R

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#' Summary of regional in-, out-, turnover and net-migration totals from an origin-destination migration flow matrix or data frame.
1+
#' Unilateral summaries of in-, out-, turnover and net-migration totals from an origin-destination migration flow matrix or data frame.
22
#'
33
#' @param m A \code{matrix} or data frame of origin-destination flows. For \code{matrix} the first and second dimensions correspond to origin and destination respectively. For a data frame ensure the correct column names are passed to \code{orig}, \code{dest} and \code{flow}.
44
#' @param drop_diagonal Logical to indicate dropping of diagonal terms, where the origin and destination are the same, in the calculation of totals. Default \code{TRUE}.
@@ -105,6 +105,7 @@ sum_region <- function(
105105
return(d)
106106
}
107107

108+
#' Alias for sum_region() for international data
108109
#' @rdname sum_region
109110
#' @export
110111
sum_country <- function(m, drop_diagonal = TRUE,
@@ -115,6 +116,7 @@ sum_country <- function(m, drop_diagonal = TRUE,
115116
include_net = include_net, international = international, na_rm = na_rm)
116117
}
117118

119+
#' Alias for sum_region() with more general naming
118120
#' @rdname sum_region
119121
#' @export
120122
sum_unilat <- function(m, drop_diagonal = TRUE,
@@ -125,7 +127,16 @@ sum_unilat <- function(m, drop_diagonal = TRUE,
125127
include_net = include_net, international = international, na_rm = na_rm)
126128
}
127129

128-
130+
#' Alias for sum_unilat() with more explicit naming
131+
#' @rdname sum_region
132+
#' @export
133+
sum_unilateral <- function(m, drop_diagonal = TRUE,
134+
orig = "orig", dest = "dest", flow = "flow",
135+
include_net = TRUE, international = TRUE, na_rm = TRUE){
136+
sum_unilat(m = m, drop_diagonal = drop_diagonal,
137+
orig = orig, dest = dest, flow = flow,
138+
include_net = include_net, international = international, na_rm = na_rm)
139+
}
129140

130141
# library(tidyverse)
131142
# library(migest)

man/sum_region.Rd

Lines changed: 20 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)