{"id":26,"date":"2010-03-02T21:21:23","date_gmt":"2010-03-03T05:21:23","guid":{"rendered":"http:\/\/ns6t.net\/word\/?page_id=26"},"modified":"2010-03-11T20:09:17","modified_gmt":"2010-03-12T04:09:17","slug":"adding-places-to-the-map","status":"publish","type":"page","link":"https:\/\/ns6t.net\/word\/?page_id=26","title":{"rendered":"Adding places to the map"},"content":{"rendered":"<p>Once I had the basic azimuthal map working, I wanted to be able to put notable cities and towns on the map too. To do this, I needed a database of places with their name, latitude\/longitude, and population. For the United States, this information is available from two government organizations: the <a href=\"http:\/\/geonames.usgs.gov\/\" target=\"_blank\">U.S. Board on Geographic Names<\/a> (part of the <a href=\"http:\/\/www.usgs.gov\/\" target=\"_blank\">U.S. Geological Survey<\/a>) and the <a href=\"http:\/\/www.census.gov\/\" target=\"_blank\">U.S. Census Bureau<\/a>.<\/p>\n<p>On the U.S. Board on Geographic Names <a href=\"http:\/\/geonames.usgs.gov\/domestic\/download_data.htm\" target=\"_blank\">download page<\/a>, I found a database of named places (e.g., cities, towns, populated places, and parks) that included the latitude\/longitude. The database has about 190,000 entries, so it was clear I needed some way to prioritize which ones to include, and population seem like the best way to prioritize.<\/p>\n<p>I wrestled with the U.S. Census Bureau&#8217;s web site for a while before I found a way to download a file with total population for places.\u00a0 It looks like a downloaded <a href=\"http:\/\/www.census.gov\/prod\/cen2000\/doc\/sf1.pdf\">Summary File 1<\/a>. This <a href=\"http:\/\/www.census.gov\/tiger\/tms\/gazetteer\/places2k.txt\">file<\/a> may have both types of information (latitude\/longitude and population) in a single file. The names, locations, and populations of non-US cities were provided by <a href=\"http:\/\/www.world-gazetteer.com\/\" target=\"_blank\">The World Gazetteer<\/a>.<\/p>\n<p>The remaining challenge is how to automatically choose which cities to put on the map and which to leave off. Population is a useful starting place, but it leaves out important landmarks. I need to figure a way to prevent listing lots of cities in high population density areas and none in the low density areas.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Once I had the basic azimuthal map working, I wanted to be able to put notable cities and towns on the map too. To do this, I needed a database of places with their name, latitude\/longitude, and population. For the United States, this information is available from two government organizations: the U.S. Board on Geographic &hellip; <a href=\"https:\/\/ns6t.net\/word\/?page_id=26\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Adding places to the map&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","meta":{"footnotes":""},"class_list":["post-26","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/pages\/26","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=26"}],"version-history":[{"count":5,"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/pages\/26\/revisions"}],"predecessor-version":[{"id":60,"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=\/wp\/v2\/pages\/26\/revisions\/60"}],"wp:attachment":[{"href":"https:\/\/ns6t.net\/word\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=26"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}