R calls the Baidu map API

Source: Internet
Author: User

Due to Ggmap not working properly

Consider using R to invoke Baidu maps API

Methods for invoking map interfaces in R
In R, you could have used the package for Google Maps directly Rgooglemaps;ggmap reference: Http://cran.r-project.org/web/packages/RgoogleMaps/RgoogleMaps.pdf Http://www.r-bloggers.com/google-maps-and-ggmap/http://journal.r-project.org/archive/2013-1/kahle-wickham.pdf http://www.milanor.net/blog/?p=534 http://blog.csdn.net/trueman007/article/details/39401547/HTTP www.r-bloggers.com/visualisation-with-r-and-google-maps/



(1) Baidu map---Static Diagram API interface Description http://developer.baidu.com/map/index.php?title=static/static-1 static map calls do not need Ak--key, The required parameters are mainly latitude and longitude, plus some realistic parameters.

(2) Baidu Map---Geocoding api:web service API http://developer.baidu.com/map/index.php?title=webapi/guide/ Webservice-geocoding need to ak--key their own registration application Ak-key:dzai6ftmf9gbjakibwlcomrs Use example: http://api.map.baidu.com/geocoder/v2/? address= Baidu Building &output=json&ak=dzai6ftmf9gbjakibwlcomrs&callback=showlocation
Results displayed: Showlocation&&showlocation ({"Status": 0, "result": {"location": {"LNG": 116.30783584945, "lat") : 40.056876296398}, "precise": 1, "confidence": +, "level": "\u5546\u52a1\u5927\u53a6"}})

(3) R call Baidu Map of the process of the current business needs: a) According to the specific geographical location to obtain latitude and longitude information B) to obtain the required static map according to latitude and longitude C) to process the static map as an object that can be processed in R, such as Ggmap D) use R to process the object as needed

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.