mapping tweets on the go

18
Mapping Tweets on the Go Convergence of Social, Mobile and Location- Based Services Shawn Shen Developer Advocate Google Nov 17, '09

Upload: ss318

Post on 05-Dec-2014

2.293 views

Category:

Technology


1 download

DESCRIPTION

Convergence of Maps, Social, and LBS on Mobile devices

TRANSCRIPT

Page 1: Mapping Tweets On The Go

Mapping Tweets on the Go

Convergence of Social, Mobile and Location-Based

Services

Shawn ShenDeveloper Advocate

Google  

Nov 17, '09

Page 2: Mapping Tweets On The Go

Three Powerful Trends

• Social Web and Apps: Facebook/Twitter • Mobile Web and Mobile Apps 

 

• Location, Maps, and LBS

Page 3: Mapping Tweets On The Go

Google Maps (now Mobile)

• Maps API V3o Designed with Model View Controller (MVC) o Optimized for Mobile apps

• Local Search APIs• Monetization

o Map Ad Unito GoogleBaro AdSense for Mobile o AdSense for Mobile Apps o AdMob...

Page 4: Mapping Tweets On The Go

Social Networks Going Geo

• Twitter o Grown 10-15x in 2009 at ~50M userso Working on geo/location APIs

Location-based Trend APIs Location-aware Tweets with Lat/Long

• Facebooko 300M+ userso Platform of Apps: $800M run rateo Working on geo-location-based services

• Social APIs and Platformso 200-300K developerso Billions of app installs

Page 5: Mapping Tweets On The Go

Mobile Apps and Mobile Web

• Mobile Appso iPhone: 100K+ apps; billions of installso Android: 

13K+ apps Google Maps Navigation 

o 100K+ developers • Mobile Web

o Usage growth 100-200% y/yo Monthly unique users 1/3 of web 80-100M 

• Ads marketo $500M+o AdMob acquired by Google

Page 6: Mapping Tweets On The Go

Convergence of the Three Trends

• Social Web and Apps: Facebook + Twitter• Mobile Web and Mobile Apps• Location-aware services on Google Maps     Google Maps + Social + Mobile   => Lots of Creative Apps

Page 7: Mapping Tweets On The Go

Dec '09 Geo Hackathon at Googleplex

• Time: 12/15 Tues• Location: 

Bodega Bay Tech Talk 1950 Charleston Ave Googleplex Mountain View, CA

• RSVP at:

http://bit.ly/2KdlYJ   or http://www.meetup.com/webmapsocial/calendar/11877554/

Page 8: Mapping Tweets On The Go

Demo App: Mapping Tweets on the Go

iUI: Library for web apps on mobile phones

Page 9: Mapping Tweets On The Go

Location-aware Tweets

Page 10: Mapping Tweets On The Go

Demo & References

http://mmmop.com Links• iUI: http://code.google.com/p/iui/• python-twitter: 

ohttp://code.google.com/p/python-twitter/• Blog by Bob Hitching: mobile web apps

ohttp://bit.ly/1Uh2Ph• Maps Javascript API V3

o http://code.google.com/apis/maps/documentation/v3/

Page 11: Mapping Tweets On The Go

How Does the Demo App Work?

• Front-endo iUI: Look and Feel of Native AppoGoogle Maps API V3: optimized for mobile

 • Back-end 

oGoogle App Engineopython-twitter libraryoTwitter APIs

Page 12: Mapping Tweets On The Go

Get Geo Location

                        navigator.geolocation.getCurrentPosition(function(position) {     // success - geolocation authorized by user.                             map.setOptions({        center: new google.maps.LatLng(                 position.coords.latitude, position.coords.longitude),        zoom: 11     });   }, function() {     // fail - geolocation denied by user. do nothing.

   });

Page 13: Mapping Tweets On The Go

Get Geo-tagged Tweets           tweets = api.GetUserTimeline()           buff = '<?xml version="1.0" encoding="UTF-8"?>' + "\n"           buff = buff + "<markers>\n"           for u in tweets:               id = u.GetId()               ddd = api.GetStatus(id)               dd = json.read(ddd)               for g in dd.iterkeys():                 if g == 'geo' and dd[g] != None:                       buff = buff + "\t<marker "                       buff = buff + 'id="' + str(u.GetId()) + '" '                       ...           buff = buff + "</markers>\n"           self.response.out.write(buff)

Page 14: Mapping Tweets On The Go

Put Geo Tweets as Markers downloadUrl('tw.php', addTweets);

function addTweets(data) {    var m = data.documentElement.getElementsByTagName("marker");   for (var i = 0; i < m.length; i++) {         ...         lat = parseFloat(m[i].getAttribute("lat"));         lng = parseFloat(m[i].getAttribute("lng"));         ...         marker = new google.maps.Marker({                          position: new google.maps.LatLng(lat, lng),                          ...                        });   }}

Page 15: Mapping Tweets On The Go

More Services: Local Search

Page 16: Mapping Tweets On The Go

Monetization: Map Ad Unit

Page 17: Mapping Tweets On The Go

Monetization: GoogleBar

Page 18: Mapping Tweets On The Go

Dec '09 Geo Hackathon• Google Maps/Earth APIs • Time: 12/15 Tues• Location: 

Bodega Bay Tech Talk 1950 Charleston Ave Googleplex Mountain View, CA

• RSVP at:

http://bit.ly/2KdlYJ   or http://www.meetup.com/webmapsocial/calendar/11877554/