Google Script, Twitter API & Google Maps

Image taken from page 12 of ‘Guide to Cambridge: the town, university and colleges … To which are added, notes upon the villages within ten miles, a map, etc’ flickr photo by The British Library shared with no copyright restriction (Flickr Commons) This is more playing with Martin‘s TAGs in Google Script and then moving it into Google Maps for visuals . . . the TAGS related functions will only work in that context but the purse Google stuff should work in any spreadsheet. Get Twitter Location by Account This function will get the user’s location as defined by their profile. So =getLoc(“twoodwar”) would return Richmond VA. This function will get the lat/long via Google Script. So =getLl(“Richmond, VA”) would return 37.5407246, -77.4360481. Keep in mind if it’s trying to get the lat/lng for someone who put “the Interwebz” as their location like OnlineCrsLady then your lat/lng may not work out that well. So that’ll let us take a chunk of TAGs data.1 and do something like this with Google Maps. I’m not going to break this chunk down quite yet. I did it at very odd hours and it works but it’s not very clean and I know there are ways to do it better.There is no shame in my game but there is some bashfulness. Pretend I’m an […]

A google map showing the data being plotted

Google Forms Interacting with Google Maps

The challenge as initially laid out was to let students log the miles they walk and have those miles show their progress from Richmond VA to Key West FL on a map. I found quite a few ways not to do this- mostly because I was attacking the problem in the wrong way. I wanted to set a point of origin, a destination direction and then map a straight line for X amount of miles. It may be possible but it feels like you’re fighting the system the whole way. I took some time off and let it marinate in my head and a much easier solution appeared. Goal In the end I realized I wanted to get the path from Richmond to Key West and then be able to add a marker to that path at any mileage point along the way. The miles would be pulled from Google Form submissions. One of the key helpers was epoly.js . It adds a number of tricks which come in handy- including the option to GetPointAtDistance along a path. I used this example for find the midpoint of a route as the starting template. I figured I’d leave the midpoint as a goal and then all I needed to do was add another marker that was placed based on the sum […]

Geo Tagging WordPress

First, go try it out if you want. Submit something. It’ll help it make more sense. I thought this would be a lot easier than I made it. I tried lots of paths and considered spending various amounts of money to make this easier. Please benefit (probably) from my wandering. I try to link in where I learned different things and, more importantly, I tried to emphasize vocabulary that might be useful to you. My goal1 was to- have a Google2 Map interface that auto-located the device allow the user to drag the marker to adjust the location plot the resulting WordPress posts on a map To make this work you do need a Google Maps API3 key and on the WordPress side you’ll need the Gravity Forms (Costs money but worth it) and Geo Mashup (free) plugins. Gravity Forms will let you create posts via a form and provision form elements via URL parameters. Geo Mashup is the friendliest way I found to display posts on a Google Map based on lat/long parameters associated with the post. Auto Locate I went to a few different places for this but ended up finding/using the handy example posted in the Google Maps API documentation. It took me a while to get there- “geolocation” is the key term. Add it to your […]

05

Inequality Mapping

A while ago (maybe a week) I had a conversation with David about inequality and mapping the data to help make it more understandable. He shared the video above with with me on Sept. 29. That got me moving. Initially, I played with the data in Google Earth. It’s pretty easy to generate circles1 with various radii2 I used this website to make the circles in only a few minutes. I played with it in Google Earth but ended up being unsatisfied with the options available in the new Google My Maps online interface. So that led me down the path of messing more directly with the Google Maps API.3 As I wandered around looking for examples I found a javascript library on Github (JQuery Location Picker) that seemed to do most of what I wanted. It let you pick a location and drop a marker with a specific circle size. My next goal was to figure out how to make a drop down list set the variable for the circle radius. Now that’s not difficult for anyone with a clue regarding javascript programming or probably anyone with a general clue about programming. I usually have a pretty good idea how this ought to work conceptually but not much of a clue what to actually write. It took me a […]

Biology Field Journal – Gravity Forms + Google Maps for WordPress

Turns out this won’t work for what I originally planned but the pattern is sound. You can see the form here and examples of the form submissions here. You’ll need Gravity Forms (pay but well worth it) and Google Maps for WordPress but the idea should work for all kinds things. The original goal was to have structured posts from students and the ability to associate those posts with a point on Google Maps. After turning on the plugins, all the work is done in Gravity Forms. Initially, make a text entry fields for latitude and separate text field for longitude. Add all the other fields you want in the mix. In this case we added some categories to do with the environment, plant descriptions etc. Gravity Forms is fairly unique in that it has post elements for WP built in. I added the Post Body and Post Title fields at the bottom. Now we just need to create the content template that’ll mix our variables into the body of the post.   You’ll notice in the image above that when ¬†you mouse over an element it displays the Field ID – in this case 2. That’s important as to add this field you’ll need to reference both the title and the field ID like so {Latitude:2}. The image below […]

Teaching a Table New Tricks

I’m doing a presentation tomorrow with Jim Groom on how to create mashups without knowing anything about programming. The fun thing is it’s presented using a mashup of communist propaganda posters and that sort of rhetoric. Good clean American fun! It may, or may not, be presented entirely in a fake Russian accent. It will entirely depend on my mood (and Jim‘s). You can also check out the full site here if you’re interested. My example takes a table of information from Wikipedia on Industrial Warfare and steps you through the ways you can change it using SIMILE’s Exhibit. If you bother to look at the actual Exhibit pages you’ll see they link back to the Google spreadsheets to show you what data had to be added to create the changes on the pages. So, you’ll start with this- Step 1 Making this data interactive– so I cut and paste the table into Excel and clean up the data a little bit. I make the html portion of Exhibit. Then I get what’s below- an interesting level of interactivity has been added. You can select/omit/sort the data now. So seeing relationships is a lot easier. Step 2 Adding the visual component– now I felt that we needed something more visual so I added some image URLs and URLs to the […]

Pretty Formatting in Google Maps w/o ANY HTML Knowledge

I don’t like what plain Google Map or Google Earth windows look like when you enter text. They always end up too wide for me and I just want a little bit more style and formatting. It just looks better and that is part of why we use computers- to produce a professional looking product. So the question is how do you get students/profs/teachers creating better looking information w/o having a bunch of time sucked away by teaching them HTML? (Yes, I realize Google does a form of this here but it’s not set up for Google Maps and involves more hassle for many by introducing the idea of networked kmz links etc.) My solution is Excel. Excel can do all sorts of neat tricks with text. So I just built what is essentially a form with a few inputs (the ones selected for this project) and then used a bunch of formulas to wrap the HTML around the information that’s entered. This is a fairly simple example but it’s smart enough to cite the picture source and know if certain information has been entered so it doesn’t botch the html if the field is left blank. You can see what it does if you unhide the columns and view the formulas then tweak it to your heart’s content. Before […]

Exhibit and Data Visualization

The kind and brilliant folks at MIT have come out with a new Exhibit API that allows for more flexibility and power. The bonus is that it looks good doing it. I’ve now revised my Google spreadsheet fed history example to use some of the new power. It’s here if you’re interested. In the end I opted to mimic their new presidents layout (much like I mimicked their old presidents layout). This time I had a better reason than pure ignorance of the API (I now have impure ignorance after all). Their new layout is really right in line with what I’d like to focus on this year- data visualization/interaction. The new layout has the map right their with the time line. I like that. Time and location on one easy interactive page. Add in their option to sort and hide/expand sets based on the data you define and you’ve got something really powerful that will help students make connections. A simple example is if I restrict my set to show only “explorers” then suddenly in the map and the time line things change. I notice explorers were mainly earlier and than none were born in the Americas (obvious to you and I but maybe the spark some kids need). Then I switch map views and I see that explorers […]

09

ITRT Summer Camp – VSTE

Hey there VSTE ITRTs! Here are links to the resources used in today’s Google Earth/Maps, GPS session. I tried to cull things down a little bit to keep it from being overwhelming. If you want to check out all the links for Google Earth feel free to browse my del.icio.us account. There’s lot more stuff there. Google Earth First, you can get Google Earth for free here so go get it if you haven’t yet. Basic Google Earth Tutorials Google’s Own Basics Juicy Geography’s PDFs Adding Time– make your KML files change using the time line feature KML Files The Google Earth Blog– all Google Earth, all the time Google Lit Trips– Books with a geographic twist The BIG Keyhole Site– lots of everything including help Google’s Outreach Showcase– where Google shows off good examples Keep in mind you can search in Google Earth for KML files. Lesson Plans/Example Files (stuff I showed you) English Examples History Examples Math Examples Science Examples (kind of big 3MB) Neat Stuff Possibilities The Next Level Make Better Balloons Make Your File From a Spreadsheet– you can make KML files from a spreadsheet and they’re pretty! Google Maps A lot of features similar to Google Earth. It will allow you to embed video in the information bubbles which is nice and I like the […]

Simile – Exhibit – Tutorial v.4

It took a while but I put together a fairly lengthy tutorial on how to make an Exhibit site that gets its info from a Google spreadsheet feed. It’s complete with tutorial files and a number of screencasts. I’m not sure it’s out of beta yet but I’m inviting anyone who’s interested to check out the tutorial and let me know if I’ve done anything stupid or made absolutely no sense in any portion (which is likely when trying to describe how the different view options work). I tried to include a rationale for using the project with Millennials as well as step-by-step directions to get a basic working copy up and running. The customization piece was a lot harder to do w/o specific requests to cover. If you want to know how to do anything I didn’t cover feel free to contact me and I’ll throw up some more video. The link is here. I’d appreciate any feedback- good or bad. Thanks, Tom