getRouteA: Get Traffic Status from amap

Description Usage Arguments Value Examples

Description

get traffic status from amap,there are c(description,expedite,congested,blocked,unkown)

Usage

1
2
3
getRouteA(orgin = "116.481499,39.990475",
  destination = "116.465063,39.999538", city = "beijing", strategy = 2,
  minione = F, firstone = T, mapkey = "71b002162d43fea08afd5b5e31b030af")

Arguments

city

character

minione

select by shortest distance

firstone

select the first one

type

character:defalut NULL ,should be rectangle/circle/NULL

location

character:location should be writtend like

name

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

radius

logical value, return the coordinates or the original results

citycode

code of city.for examples fuzhou is 0591

key

amap key

output

xml or json

Value

A vector contains description,expedite,congested,blocked,unkown

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
## rectangle
location='119.278861,26.106208;119.336454,26.078304'
a=getTrafficStatus(location = location,key = amap_key,type='rectangle')

## circle
location='119.278861,26.106208'
b=getTrafficStatus(type='circle',location = location,key = amap_key)

## road
location='119.278861,26.106208'
c=getTrafficStatus(type='name',key = amap_key,name='鍙ょ敯璺㤼㸰?<U+3E66>')

## End(Not run)

daigazi/bamapr documentation built on May 14, 2019, 3:28 p.m.