Skip to content

Commit

Permalink
improve docs for return val of match_pts_to_graph for #103
Browse files Browse the repository at this point in the history
  • Loading branch information
mpadge committed Sep 4, 2022
1 parent f0fe7ab commit a8bd28d
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 10 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: dodgr
Title: Distances on Directed Graphs
Version: 0.2.15.013
Version: 0.2.15.014
Authors@R: c(
person("Mark", "Padgham", , "[email protected]", role = c("aut", "cre")),
person("Andreas", "Petutschnig", role = "aut"),
Expand Down
14 changes: 11 additions & 3 deletions R/match-points.R
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,22 @@ pre_process_xy <- function (xy) {
#' `dodgr_streetnet` object.
#' @param distances If `TRUE`, return a 'data.frame' object with 'index' column
#' as described in return value; and additional 'dist' column with perpendicular
#' distance to nearest edge in graph.
#' distance to nearest edge in graph. See description of return value for
#' details.
#' @inheritParams match_pts_to_verts
#'
#' @return For 'distances = FALSE' (default), a vector index matching the `xy`
#' coordinates to nearest edges. For bi-directional edges, only one match is
#' returned, and it is up to the user to identify and suitably process matching
#' edge pairs. For 'distances = TRUE', a 'data.frame' of two columns, "index"
#' as described above, and "dist".
#' edge pairs. For 'distances = TRUE', a 'data.frame' of two columns:
#' \itemize{
#' \item "index" The index of closest edges in "graph", as described above.
#' \item "d_signed" The perpendicular distance from ech point to the nearest
#' edge, with negative distances denoting points to the left of edges, and
#' positive distances denoting points to the right. Distances of zero denote
#' points lying precisely on the line of an edge (potentially including cases
#' where nearest point of bisection lies beyond the actual edge).
#' }
#' @family match
#' @export
#' @examples
Expand Down
2 changes: 1 addition & 1 deletion codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"codeRepository": "https://github.com/ATFutures/dodgr",
"issueTracker": "https://github.com/ATFutures/dodgr/issues",
"license": "https://spdx.org/licenses/GPL-3.0",
"version": "0.2.15.013",
"version": "0.2.15.014",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
Expand Down
11 changes: 9 additions & 2 deletions man/match_points_to_graph.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 11 additions & 3 deletions man/match_pts_to_graph.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a8bd28d

Please sign in to comment.