Learn R Programming

bfsMaps (version 1.99.4)

GeoCode: Get the Coordinates For a Given Address

Description

Get the coordinates for a given address in Switzerland. The function just prepares the url needed to feed the GeoAdmin API.

Usage

GeoCode(x)

Value

a data.frame with 5 columns

detail, lat, lon, x, y

Arguments

x

a character vector containing addresses in the form of "street number place"

Author

Andri Signorell <andri@signorell.net>

Details

See further details in https://api3.geo.admin.ch/services/sdiservices.html#find.

Examples

Run this code
if (FALSE) {
  adr <- c("Quaderaweg 3 Trimmis","chemin des Fraisiers 19 Grand-Lancy",
          "Im Spitzacker 21 Basel","Rue du Moleson 8 Broc")
  GeoCode(adr)
  }

Run the code above in your browser using DataLab