diff --git a/R/osm_get_changesets.R b/R/osm_get_changesets.R index 6f6a4eb..513c621 100644 --- a/R/osm_get_changesets.R +++ b/R/osm_get_changesets.R @@ -75,11 +75,9 @@ #' @export #' #' @examples -#' \dontrun{ #' chaset <- osm_get_changesets(changeset_id = 137595351, include_discussion = TRUE) #' chaset #' chaset$discussion -#' } osm_get_changesets <- function(changeset_id, include_discussion = FALSE, format = c("R", "sf", "xml", "json"), tags_in_columns = FALSE) { format <- match.arg(format) diff --git a/R/osm_get_gpx_metadata.R b/R/osm_get_gpx_metadata.R index ea31266..6d7ce35 100644 --- a/R/osm_get_gpx_metadata.R +++ b/R/osm_get_gpx_metadata.R @@ -28,10 +28,8 @@ #' @export #' #' @examples -#' \dontrun{ #' trk_meta <- osm_get_gpx_metadata(gpx_id = 3498170) #' trk_meta -#' } osm_get_gpx_metadata <- function(gpx_id, format = c("R", "sf", "xml")) { format <- match.arg(format) .format <- if (format == "sf") "R" else format diff --git a/R/osm_get_notes.R b/R/osm_get_notes.R index f88b84c..e894ed1 100644 --- a/R/osm_get_notes.R +++ b/R/osm_get_notes.R @@ -75,10 +75,8 @@ #' @export #' #' @examples -#' \dontrun{ #' note <- osm_get_notes(note_id = "2067786") #' note -#' } osm_get_notes <- function(note_id, format = c("R", "sf", "xml", "rss", "json", "gpx")) { format <- match.arg(format) .format <- if (format == "sf") "R" else format diff --git a/R/osm_get_objects.R b/R/osm_get_objects.R index 7faf675..fd163ee 100644 --- a/R/osm_get_objects.R +++ b/R/osm_get_objects.R @@ -44,14 +44,12 @@ #' @export #' #' @examples -#' \dontrun{ #' obj <- osm_get_objects( #' osm_type = c("node", "way", "way", "relation", "relation", "node"), #' osm_id = c("35308286", "13073736", "235744929", "40581", "341530", "1935675367"), #' version = c(1, 3, 2, 5, 7, 1) #' ) #' obj -#' } osm_get_objects <- function(osm_type, osm_id, version, full_objects = FALSE, format = c("R", "xml", "json"), tags_in_columns = FALSE) { format <- match.arg(format) diff --git a/R/osm_get_user_details.R b/R/osm_get_user_details.R index 1b7f1a1..1ce8436 100644 --- a/R/osm_get_user_details.R +++ b/R/osm_get_user_details.R @@ -56,10 +56,8 @@ #' @export #' #' @examples -#' \dontrun{ #' usrs <- osm_get_user_details(user_id = c(1, 24, 44, 45, 46, 48, 49, 50)) #' usrs -#' } osm_get_user_details <- function(user_id, format = c("R", "xml", "json")) { format <- match.arg(format) diff --git a/R/osm_query_changesets.R b/R/osm_query_changesets.R index 54e0fea..73741ff 100644 --- a/R/osm_query_changesets.R +++ b/R/osm_query_changesets.R @@ -91,7 +91,6 @@ #' @export #' #' @examples -#' \dontrun{ #' chst_ids <- osm_query_changesets(changeset_ids = c(137627129, 137625624)) #' chst_ids #' @@ -109,7 +108,6 @@ #' closed = TRUE #' ) #' chsts2 -#' } osm_query_changesets <- function(bbox, user, time, time_2, open, closed, changeset_ids, order = c("newest", "oldest"), limit = getOption("osmapir.api_capabilities")$api$changesets["default_query_limit"], format = c("R", "sf", "xml", "json"), tags_in_columns = FALSE) { diff --git a/R/osmapi_changesets.R b/R/osmapi_changesets.R index b0cb935..fdd4f6f 100644 --- a/R/osmapi_changesets.R +++ b/R/osmapi_changesets.R @@ -270,11 +270,9 @@ osm_create_changeset <- function(comment, ..., #' @noRd #' #' @examples -#' \dontrun{ #' chaset <- osm_read_changeset(changeset_id = 137595351, include_discussion = TRUE) #' chaset #' chaset$discussion -#' } osm_read_changeset <- function(changeset_id, include_discussion = FALSE, format = c("R", "xml", "json"), tags_in_columns = FALSE) { format <- match.arg(format) @@ -455,10 +453,8 @@ osm_close_changeset <- function(changeset_id) { #' @export #' #' @examples -#' \dontrun{ #' chaset <- osm_download_changeset(changeset_id = 137003062) #' chaset -#' } osm_download_changeset <- function(changeset_id, format = c("R", "osc", "xml")) { format <- match.arg(format) @@ -617,7 +613,6 @@ osm_download_changeset <- function(changeset_id, format = c("R", "osc", "xml")) #' @noRd #' #' @examples -#' \dontrun{ #' chst_ids <- osm_query_changesets(changeset_ids = c(137627129, 137625624)) #' chst_ids #' @@ -635,7 +630,6 @@ osm_download_changeset <- function(changeset_id, format = c("R", "osc", "xml")) #' closed = "true" #' ) #' chsts2 -#' } .osm_query_changesets <- function(bbox = NULL, user = NULL, time = NULL, time_2 = NULL, open = NULL, closed = NULL, changeset_ids = NULL, order = NULL, limit = getOption( diff --git a/R/osmapi_elements.R b/R/osmapi_elements.R index 083f7e5..80d7e9a 100644 --- a/R/osmapi_elements.R +++ b/R/osmapi_elements.R @@ -213,7 +213,6 @@ osm_create_object <- function(x, changeset_id) { #' @noRd #' #' @examples -#' \dontrun{ #' node <- osm_read_object(osm_type = "node", osm_id = 35308286) #' node #' @@ -222,7 +221,6 @@ osm_create_object <- function(x, changeset_id) { #' #' rel <- osm_read_object(osm_type = "relation", osm_id = "40581") #' rel -#' } osm_read_object <- function(osm_type = c("node", "way", "relation"), osm_id, format = c("R", "xml", "json"), tags_in_columns = FALSE) { osm_type <- match.arg(osm_type) @@ -553,7 +551,6 @@ osm_delete_object <- function(x, changeset_id) { #' @export #' #' @examples -#' \dontrun{ #' node <- osm_history_object(osm_type = "node", osm_id = 35308286) #' node #' @@ -562,7 +559,6 @@ osm_delete_object <- function(x, changeset_id) { #' #' rel <- osm_history_object(osm_type = "relation", osm_id = "40581") #' rel -#' } osm_history_object <- function(osm_type = c("node", "way", "relation"), osm_id, format = c("R", "xml", "json"), tags_in_columns = FALSE) { osm_type <- match.arg(osm_type) @@ -624,7 +620,6 @@ osm_history_object <- function(osm_type = c("node", "way", "relation"), osm_id, #' @noRd #' #' @examples -#' \dontrun{ #' node <- osm_version_object(osm_type = "node", osm_id = 35308286, version = 1) #' node #' @@ -633,7 +628,6 @@ osm_history_object <- function(osm_type = c("node", "way", "relation"), osm_id, #' #' rel <- osm_version_object(osm_type = "relation", osm_id = "40581", version = 3) #' rel -#' } osm_version_object <- function(osm_type = c("node", "way", "relation"), osm_id, version, format = c("R", "xml", "json"), tags_in_columns = FALSE) { osm_type <- match.arg(osm_type) @@ -710,7 +704,6 @@ osm_version_object <- function(osm_type = c("node", "way", "relation"), osm_id, #' @noRd #' #' @examples -#' \dontrun{ #' node <- osm_fetch_objects(osm_type = "nodes", osm_ids = c(35308286, 1935675367)) #' node #' @@ -720,7 +713,6 @@ osm_version_object <- function(osm_type = c("node", "way", "relation"), osm_id, #' # Specific versions #' rel <- osm_fetch_objects(osm_type = "relations", osm_ids = c("40581", "341530"), versions = c(3, 1)) #' rel -#' } osm_fetch_objects <- function(osm_type = c("nodes", "ways", "relations"), osm_ids, versions, format = c("R", "xml", "json"), tags_in_columns = FALSE) { osm_type <- match.arg(osm_type) @@ -1010,13 +1002,11 @@ osm_ways_node <- function(node_id, format = c("R", "xml", "json"), tags_in_colum #' @noRd #' #' @examples -#' \dontrun{ #' way <- osm_full_object(osm_type = "way", osm_id = 13073736) #' way #' #' rel <- osm_full_object(osm_type = "relation", osm_id = "40581") #' rel -#' } osm_full_object <- function(osm_type = c("way", "relation"), osm_id, format = c("R", "xml", "json"), tags_in_columns = FALSE) { osm_type <- match.arg(osm_type) diff --git a/R/osmapi_gps_traces.R b/R/osmapi_gps_traces.R index 1addb38..282a98c 100644 --- a/R/osmapi_gps_traces.R +++ b/R/osmapi_gps_traces.R @@ -334,10 +334,8 @@ osm_update_gpx <- function(gpx_id, name, description, tags, #' @noRd #' #' @examples -#' \dontrun{ #' trk_meta <- osm_get_metadata_gpx(gpx_id = 3498170) #' trk_meta -#' } osm_get_metadata_gpx <- function(gpx_id, format = c("R", "xml")) { format <- match.arg(format) req <- osmapi_request(authenticate = TRUE) @@ -393,14 +391,12 @@ osm_get_metadata_gpx <- function(gpx_id, format = c("R", "xml")) { #' @export #' #' @examples -#' \dontrun{ #' trk_data <- osm_get_data_gpx(gpx_id = 3498170, format = "R") #' trk_data #' #' ## get attributes #' attr(trk_data, "track") #' attr(trk_data, "gpx_attributes") -#' } osm_get_data_gpx <- function(gpx_id, format) { if (missing(format)) { ext <- "data" diff --git a/R/osmapi_map_notes.R b/R/osmapi_map_notes.R index 5fdc435..52e74ee 100644 --- a/R/osmapi_map_notes.R +++ b/R/osmapi_map_notes.R @@ -246,10 +246,8 @@ osm_read_bbox_notes <- function(bbox, limit = 100, closed = 7, format = c("R", " #' @noRd #' #' @examples -#' \dontrun{ #' note <- osm_read_note(note_id = "2067786") #' note -#' } osm_read_note <- function(note_id, format = c("R", "xml", "rss", "json", "gpx")) { format <- match.arg(format) diff --git a/R/osmapi_user_data.R b/R/osmapi_user_data.R index 1ec5781..23ce05a 100644 --- a/R/osmapi_user_data.R +++ b/R/osmapi_user_data.R @@ -85,10 +85,8 @@ #' @noRd #' #' @examples -#' \dontrun{ #' usr <- osm_details_user(user_id = "11725140") #' usr -#' } osm_details_user <- function(user_id, format = c("R", "xml", "json")) { format <- match.arg(format) @@ -225,10 +223,8 @@ osm_details_user <- function(user_id, format = c("R", "xml", "json")) { #' @noRd #' #' @examples -#' \dontrun{ #' usrs <- osm_details_users(user_ids = c(1, 24, 44, 45, 46, 48, 49, 50)) #' usrs -#' } osm_details_users <- function(user_ids, format = c("R", "xml", "json")) { format <- match.arg(format) diff --git a/R/osmchange.R b/R/osmchange.R index e12df76..ab5d083 100644 --- a/R/osmchange.R +++ b/R/osmchange.R @@ -26,7 +26,6 @@ #' @export #' #' @examples -#' \dontrun{ #' obj <- osm_get_objects( #' osm_type = c("node", "way", "way", "relation", "relation", "node"), #' osm_id = c("35308286", "13073736", "235744929", "40581", "341530", "1935675367"), @@ -34,7 +33,6 @@ #' ) #' osmch <- osmchange_modify(obj) #' osmch -#' } osmchange_modify <- function(x, tag_keys, members = FALSE, lat_lon = FALSE, format = c("R", "osc", "xml")) { format <- match.arg(format) stopifnot(inherits(x, "osmapi_objects")) @@ -149,13 +147,11 @@ osmchange_modify <- function(x, tag_keys, members = FALSE, lat_lon = FALSE, form #' @export #' #' @examples -#' \dontrun{ #' obj_id <- osmapi_objects(data.frame( #' type = c("way", "way", "relation", "node"), #' id = c("722379703", "629132242", "8387952", "4739010921") #' )) #' osmchange_del <- osmchange_delete(obj_id) -#' } osmchange_delete <- function(x, delete_if_unused = FALSE, format = c("R", "osc", "xml")) { format <- match.arg(format) diff --git a/R/tags_list-wide.r b/R/tags_list-wide.r index 7425563..a2786cb 100644 --- a/R/tags_list-wide.r +++ b/R/tags_list-wide.r @@ -25,7 +25,6 @@ #' @export #' #' @examples -#' \dontrun{ #' peaks_wide <- osm_get_objects( #' osm_type = "nodes", osm_id = c(35308286, 1935675367), tags_in_columns = TRUE #' ) @@ -41,7 +40,6 @@ #' cities_list <- osm_get_objects(osm_type = "relations", osm_id = c("40581", "341530")) #' # Column name clash: #' cities_wide <- tags_list2wide(cities_list) -#' } tags_list2wide <- function(x) { if (!inherits(x, "osmapi_objects") && !inherits(x, "osmapi_changesets")) { stop("x must be an `osmapi_objects` or `osmapi_changesets` object.") diff --git a/man/osm_download_changeset.Rd b/man/osm_download_changeset.Rd index 386a807..dcc27b8 100644 --- a/man/osm_download_changeset.Rd +++ b/man/osm_download_changeset.Rd @@ -27,11 +27,9 @@ Returns the \href{https://wiki.openstreetmap.org/wiki/OsmChange}{OsmChange} docu } } \examples{ -\dontrun{ chaset <- osm_download_changeset(changeset_id = 137003062) chaset } -} \seealso{ Other get changesets' functions: \code{\link{osm_get_changesets}()}, diff --git a/man/osm_get_changesets.Rd b/man/osm_get_changesets.Rd index 0939e56..4bcfd40 100644 --- a/man/osm_get_changesets.Rd +++ b/man/osm_get_changesets.Rd @@ -91,12 +91,10 @@ this changeset. To access this information use \code{\link[=osm_download_changes } } \examples{ -\dontrun{ chaset <- osm_get_changesets(changeset_id = 137595351, include_discussion = TRUE) chaset chaset$discussion } -} \seealso{ Other get changesets' functions: \code{\link{osm_download_changeset}()}, diff --git a/man/osm_get_data_gpx.Rd b/man/osm_get_data_gpx.Rd index a66d653..7ef2fb4 100644 --- a/man/osm_get_data_gpx.Rd +++ b/man/osm_get_data_gpx.Rd @@ -31,7 +31,6 @@ If you request refers to a multi-file archive the response when you force \code{ a non-standard simple concatenation of the files. } \examples{ -\dontrun{ trk_data <- osm_get_data_gpx(gpx_id = 3498170, format = "R") trk_data @@ -39,7 +38,6 @@ trk_data attr(trk_data, "track") attr(trk_data, "gpx_attributes") } -} \seealso{ Other get GPS' functions: \code{\link{osm_get_gpx_metadata}()}, diff --git a/man/osm_get_gpx_metadata.Rd b/man/osm_get_gpx_metadata.Rd index a402162..e75bf8e 100644 --- a/man/osm_get_gpx_metadata.Rd +++ b/man/osm_get_gpx_metadata.Rd @@ -33,11 +33,9 @@ Use this to access the metadata about GPX files. Available without authenticatio Otherwise only usable by the owner account and requires authentication. } \examples{ -\dontrun{ trk_meta <- osm_get_gpx_metadata(gpx_id = 3498170) trk_meta } -} \seealso{ Other get GPS' functions: \code{\link{osm_get_data_gpx}()}, diff --git a/man/osm_get_notes.Rd b/man/osm_get_notes.Rd index eb1c7ee..1bc3e32 100644 --- a/man/osm_get_notes.Rd +++ b/man/osm_get_notes.Rd @@ -82,11 +82,9 @@ For \code{format} in \code{"rss"}, and \code{"gpx"}, a \link[xml2:oldclass]{xml2 Returns the existing note with the given ID. } \examples{ -\dontrun{ note <- osm_get_notes(note_id = "2067786") note } -} \seealso{ Other get notes' functions: \code{\link{osm_feed_notes}()}, diff --git a/man/osm_get_objects.Rd b/man/osm_get_objects.Rd index 1d0b1b6..6def889 100644 --- a/man/osm_get_objects.Rd +++ b/man/osm_get_objects.Rd @@ -61,7 +61,6 @@ use the Overpass API. A similar function to download OSM objects by \code{type} the \pkg{osmdata} function \code{opq_osm_id()}. } \examples{ -\dontrun{ obj <- osm_get_objects( osm_type = c("node", "way", "way", "relation", "relation", "node"), osm_id = c("35308286", "13073736", "235744929", "40581", "341530", "1935675367"), @@ -69,7 +68,6 @@ obj <- osm_get_objects( ) obj } -} \seealso{ Other get OSM objects' functions: \code{\link{osm_bbox_objects}()}, diff --git a/man/osm_get_user_details.Rd b/man/osm_get_user_details.Rd index f0ad41c..e555391 100644 --- a/man/osm_get_user_details.Rd +++ b/man/osm_get_user_details.Rd @@ -65,11 +65,9 @@ Returns a list with the following json structure: Details of users } \examples{ -\dontrun{ usrs <- osm_get_user_details(user_id = c(1, 24, 44, 45, 46, 48, 49, 50)) usrs } -} \seealso{ Other users' functions: \code{\link{osm_details_logged_user}()}, diff --git a/man/osm_history_object.Rd b/man/osm_history_object.Rd index f9c5bed..d824469 100644 --- a/man/osm_history_object.Rd +++ b/man/osm_history_object.Rd @@ -32,7 +32,6 @@ returns a list with a json structure following the \href{https://wiki.openstreet Retrieves all old versions of an object from OSM. } \examples{ -\dontrun{ node <- osm_history_object(osm_type = "node", osm_id = 35308286) node @@ -42,7 +41,6 @@ way rel <- osm_history_object(osm_type = "relation", osm_id = "40581") rel } -} \seealso{ Other get OSM objects' functions: \code{\link{osm_bbox_objects}()}, diff --git a/man/osm_query_changesets.Rd b/man/osm_query_changesets.Rd index 264f6a8..2878245 100644 --- a/man/osm_query_changesets.Rd +++ b/man/osm_query_changesets.Rd @@ -121,7 +121,6 @@ Te valid formats for \code{time} and \code{time_2} parameters are anything that \href{https://ruby-doc.org/stdlib-2.7.0/libdoc/time/rdoc/Time.html#method-c-parse}{\code{Time.parse} Ruby function} will parse. } \examples{ -\dontrun{ chst_ids <- osm_query_changesets(changeset_ids = c(137627129, 137625624)) chst_ids @@ -140,7 +139,6 @@ chsts2 <- osm_query_changesets( ) chsts2 } -} \seealso{ Other get changesets' functions: \code{\link{osm_download_changeset}()}, diff --git a/man/osmchange_delete.Rd b/man/osmchange_delete.Rd index 3afddf2..e9995bc 100644 --- a/man/osmchange_delete.Rd +++ b/man/osmchange_delete.Rd @@ -33,14 +33,12 @@ lead to an error, and the whole diff upload would fail. Setting the attribute wi deleted objects to not generate an error. } \examples{ -\dontrun{ obj_id <- osmapi_objects(data.frame( type = c("way", "way", "relation", "node"), id = c("722379703", "629132242", "8387952", "4739010921") )) osmchange_del <- osmchange_delete(obj_id) } -} \seealso{ Other OsmChange's functions: \code{\link{osm_diff_upload_changeset}()}, diff --git a/man/osmchange_modify.Rd b/man/osmchange_modify.Rd index 7f5acba..9b2ff29 100644 --- a/man/osmchange_modify.Rd +++ b/man/osmchange_modify.Rd @@ -41,7 +41,6 @@ Prepare data to update tags, members and/or latitude and longitude. removed if \code{tag_keys} is not specified. See \code{\link[=osm_get_objects]{osm_get_objects()}} for examples of the format. } \examples{ -\dontrun{ obj <- osm_get_objects( osm_type = c("node", "way", "way", "relation", "relation", "node"), osm_id = c("35308286", "13073736", "235744929", "40581", "341530", "1935675367"), @@ -50,7 +49,6 @@ obj <- osm_get_objects( osmch <- osmchange_modify(obj) osmch } -} \seealso{ Other OsmChange's functions: \code{\link{osm_diff_upload_changeset}()}, diff --git a/man/tags_list-wide.Rd b/man/tags_list-wide.Rd index 7e16c0a..25f250e 100644 --- a/man/tags_list-wide.Rd +++ b/man/tags_list-wide.Rd @@ -32,7 +32,6 @@ By default, functions returning \code{osmapi_objects} or \code{osmapi_changesets but can return the results in a wide format using the parameter \code{tags_in_columns = TRUE}. } \examples{ -\dontrun{ peaks_wide <- osm_get_objects( osm_type = "nodes", osm_id = c(35308286, 1935675367), tags_in_columns = TRUE ) @@ -49,7 +48,6 @@ cities_list <- osm_get_objects(osm_type = "relations", osm_id = c("40581", "3415 # Column name clash: cities_wide <- tags_list2wide(cities_list) } -} \seealso{ Other methods: \code{\link{st_as_sf}}