R語言amapGeocode包,getCoord函數(shù)智亮,從位置請求中提取坐標(biāo)
# remotes::install_github('womeimingzi11/amapGeocode')
# Sun Nov 15 11:45:35 2020 -
# 字符編碼:UTF-8
# R 版本:R x64 4.0.3 for window 10
# cgh163email@163.com
# 個(gè)人筆記不負(fù)責(zé)任
# —— 拎了個(gè)梨??
.rs.restartR()
rm(list=ls());gc()
# getCoord函數(shù)忆某,從位置請求中提取坐標(biāo)
library(dplyr)
library(amapGeocode)
# Before the `getCoord()` is executed,
# the token should be set by `option(amap_key = 'key')`
# or set by key argument in `getCoord()`
options(amap_key='5**********fa00')
# Get geocode as a XML
getCoord('廣州塔')
# lng lat formatted_address country province city district township
# 1: 113.2644 23.12916 廣東省廣州市 中國 廣東省 廣州市 NA NA
# street number citycode adcode
# 1: NA NA 020 440100
# Sun Nov 15 15:50:25 2020 --end
#