Learn R Programming

osmextract (version 0.2.1)

oe_match_pattern: Check patterns in the provider's databases

Description

This function is used to explore the provider's databases and look for patterns. This function can be useful in combination with oe_match() and oe_get() for an easy match. See Examples.

Usage

oe_match_pattern(
  pattern,
  provider = "geofabrik",
  match_by = "name",
  full_row = FALSE
)

Arguments

pattern

Character string representing the pattern that should be explored.

provider

Which provider should be used? Check a summary of all available providers with oe_providers().

match_by

Column name of the provider's database that will be used to find the match.

full_row

Boolean. Return all columns for the matching rows? FALSE by default.

Value

A character vector or a subset of the provider's database.

Examples

Run this code
# NOT RUN {
oe_match("Yorkshire", quiet = FALSE)
# }
# NOT RUN {
oe_match_pattern("Yorkshire")

res = oe_match_pattern("Yorkshire", full_row = TRUE)
sf::st_drop_geometry(res)[1:3]
# }

Run the code above in your browser using DataLab