Description Usage Arguments Value Examples
get traffic status from amap,there are c(description,expedite,congested,blocked,unkown)
1 2 3 |
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 |
city |
character |
citycode |
code of city.for examples fuzhou is 0591 |
key |
amap key |
output |
xml or json |
A vector contains description,expedite,congested,blocked,unkown
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ## Not run:
## rectangle
location='119.278861,26.106208;119.336454,26.078304'
# the rectangle can't be too big,diagonal must be shorted than 10km
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='鍙ょ敯璺愼㹦')
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.