Quarter Life Crisis

The world according to Sven-S. Porst

« ScrollingMainSeason’s Greetings »

Where am I?

338 words

Scott asks about how to find out the latitude and latitude for a country. I suppose that's hard to achieve as countries are not points. At best people could give a polygon of locations that describes a country – several polygons in fact, seeing that there are disconnected countries such as the U.K. or the U.S.

I don't think that simply taking the coordinates of the capital or the centre of the country and deducting in which country web sites are by proximity will work. In fact, I am pretty damn sure it's bound to fail miserably. While it seems rather easy to find out the longitude and latitude for most locations by esoteric means, reverse lookup seems to be non-existent. Probably because providing such a service would require more work than simply having a list of places with their respective latitudes and longitudes.

My best guess for this problem would be a very traditional one. For decades, the Mac has had its Map control panel that actually did some kind of reverse lookup. Click on a place on the map and if you're lucky you'll hit a city whose name will be displayed. This is still present in OSX, in the Date and Time system preference to choose time zones. So that would be a place to start looking at.

And as usual gut feeling just takes me to the right places on my Mac. Just look at /System/Library/PreferencePanes/DateAndTime.prefPane/Contents/Resources/TimeZone.prefPane/Contents/Resources/all_cities_adj.plist containing the coordinates of about 200 places, along with their names and country codes. While this will be too rough, it may be a starting point or at least the random Mac fact of the day.

That was the fun bit. To get the real work done, why don't use GeoURL themselves? Their database is usually able to tell which town sites are close to and which country they're in.

Hm, the last point was a bit too obvious perhaps – if you want to use GeoURL data, you may as well want to use GeoURL...

September 22, 2003, 23:17

Trackback

Trackback “In Defense of Approximation or Maybe I'm an Idiot but Approximations Aren't Always Bad” from The FuzzyBlog:

In my recent blog entry about "Why Lat / Long is a Country" I’ve taken more than a bit of flack.  Most nota

September 23, 2003, 13:09

Comments

Comment by CG Welch: User icon

It would be great if everyone made sure to list their GeoURL info.

But they don’t. So I think Scott’s first step is in the right direction. It looks as though he plans to use the CIA data solely as a general parameter used when GeoURL information is missing.

I can live with a Feedster search of “Canadian” blogs and know that Toronto gets dumped in with Montreal. I am sure I’ll also have the option to see those who have used LAT/LON for more exact location.

September 23, 2003, 14:31

Comment by ssp: User icon

I think it’s good to see Scott supporting geographic locations. I also think that location is a different notion from the contry you happen to reside in. Thus I see the approach of rough approximation failing for both large and small countries.

In large countries as the U.S. you may be thousands of kilometres away from the point that is allocated to you. If say, the countrie’s capital is used as a point and you live in San Diego, you may be more interested in what’s happening in Mexico than what’s going on at the East coast.

In small countries there’s a different problem. Imagine living in Belgium. Depending on where you are you’ll probably interested what’s going on in Holland or France as well. Take this to an extreme and take Luxemburg…

The latter may be a manifestation of the diminuishing importance of actual countries for your everyday life in places like the EU. You may have different passports than the people a few kilometres away but they’re just your neightbours.

September 23, 2003, 21:39

Add your comment

« ScrollingMainSeason's Greetings »

Comments on

Photos

Categories

Me

This page

Out & About

pinboard Links

People

Ego-Linking