getCoordinate: Get coordiante from address Take in address and return the...

Description Usage Arguments Value Examples

View source: R/getCoordinate.R

Description

Get coordiante from address Take in address and return the coordinate

Usage

1
2
getCoordinate(address, city = NULL, output = "json", formatted = F,
  limit = 600)

Arguments

address

address

city

the city of the address, optional

output

should be "json" or "xml", the type of the result

formatted

logical value, return the coordinates or the original results

limit

integer value.If the length of address exceeded limit, function will run in parallel

Value

A vector contains the corresponding coordiante. If "formatted=TRUE", return the numeric coordinates, otherwise return json or xml type result, depents on the argument "output". If the length of address is larger than 1, the result is a matrix.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run:  
## json output
getCoordinate('<e5><8c><97><e4><ba><ac><e5><a4><a7><e5><ad><a6>')

## xml output
getCoordinate('<e5><8c><97><e4><ba><ac><e5><a4><a7><e5><ad><a6>', output='xml')

## formatted
getCoordinate('<e5><8c><97><e4><ba><ac><e5><a4><a7><e5><ad><a6>', formatted = T)

## vectorization, return a matrix
getCoordinate(c('<e5><8c><97><e4><ba><ac><e5><a4><a7><e5><ad><a6>', '<e6><b8><85><e5><8d><8e><e5><a4><a7><e5><ad><a6>'), formatted = T)

## End(Not run)

badbye/baidumap documentation built on June 4, 2017, 12:12 a.m.