Skip to content

Instantly share code, notes, and snippets.

View govvin's full-sized avatar

거윈 | Win govvin

View GitHub Profile
@govvin
govvin / manilaMapathon_edits.tsv
Created January 26, 2016 09:36
U.S. Embassy Mapathon stats, 2016-023
We can make this file beautiful and searchable if this error is corrected: It looks like row 8 should actually have 32 columns, instead of 1. in line 7.
ekip osmuser_uid osmuser_name changeset objects objects_c objects_m objects_d node_c way_c relation_c node_m way_m relation_m node_d way_d relation_d poi_total_nodes node_amenity node_shop node_office node_power node_place node_man_made node_history node_tourism node_leisure way_highway way_waterway way_building way_landuse way_man_made
0 900923 curran74 0 4053 3899 87 67 3216 683 0 82 5 0 60 7 0 0 0 0 0 0 0 0 0 0 0 11 4 663 1 0
0 3089153 Sea Tea Zen 0 3656 3551 89 16 3132 419 0 67 22 0 15 1 0 0 0 0 0 0 0 0 0 0 0 0 23 383 12 0
0 3556440 sch93 0 2006 1874 120 12 1550 324 0 108 12 0 9 3 0 0 0 0 0 0 0 0 0 0 0 3 12 307 0 0
0 3556185 osmcr 0 1853 1846 7 0 1586 259 1 4 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 7 225 15 0
0 3556439 Fdk Ville 0 1592 1433 99 60 1152 281 0 4 95 0 48 12 0 0 0 0 0 0 0 0 0 0 0 0 0 141 0 0
0 3556479 Jofel Bayron 0 1884 1354 490 40 1284 70 0 428 62 0 40 0 0 0 0 0 0 0 0 0 0 0 0 6 14 24 18 0
0
@govvin
govvin / otq_manila_fire_brigades.md
Created May 9, 2016 07:26
Overpass Turbo query to gather fire stations, volunteer fire brigades, and fire hydrants in Manila.
/*
Query for ALL fire stations and hydrants
//{s}.tile.openstreetmap.org/{z}/{x}/{y}.png
//{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png
//tiles.wmflabs.org/bw-mapnik/{z}/{x}/{y}.png

//{s}.tile.stamen.com/toner/{z}/{x}/{y}.png
//toolserver.org/~cmarqu/hill/{z}/{x}/{y}.png
//a.tile2.opencyclemap.org/transport/{z}/{x}/{y}.png
@govvin
govvin / OTQ_event_edits_geocodearea.md
Created February 24, 2016 11:41
Query edits made in a geocoded region, by enumerated uids, within a date range. Perfect for events like mapathons and training workshops.

#Overpass Turbo Query

/* Overpass Turbo Query for edits made during mapathons, and similar mapping events. */

// set variables
{{dates="2016-02-22T00:00:00Z", "2016-02-25T23:59:59Z"}}
{{party=1041828}}
@govvin
govvin / otq_party_edits.md
Created March 8, 2016 02:58
query for changes made during events, given a geographical area, and a list of OSM uids

#Overpass Turbo query: for edits made during events, given a geographical area, and a list of OSM uids

[out:json]
[timeout:55];

{{dates="2016-02-23T00:00:00+8", "2016-03-07T00:00:00+8"}}
{{party=1041828}}

//union areas of study
@govvin
govvin / otq_ql_querying_changes.md
Last active May 12, 2016 04:20
Overpass Turbo QL :: querying for changes

There are several ways to query for modifications using OverPass, with slightly varying results. Use wisely.

##Using diffs

//Overpass QL for querying results
//http://overpass-turbo.eu/s/b6e

//[out:csv(::lat,::lon,::type, ::version, ::user, place,name)]
[diff:"2016-05-07T00:00:00+8","2016-05-14T00:00:00+8"]; 
@govvin
govvin / otq_ql_bus_routes.txt
Created May 11, 2016 10:59
Display Public Transport routes in given bbox
/*
This has been generated by the overpass-turbo wizard.
The original search was:
“route=bus”
*/
[out:json][timeout:25];
// gather results
(
// query part for: “route=bus”
node["route"="bus"]({{bbox}});
@govvin
govvin / otq_ql_manila_districts.txt
Created May 11, 2016 06:27
query Overpass Turbo for all districts of the city of Manila
[out:json];
area[name~"Manila"]["admin_level"=6]->.a;
rel["admin_level"=7](area.a);
out geom;
{{style:
node {
width: 0;
opacity:0;
fill-opacity:0;
@govvin
govvin / otq_mapathon_edits.md
Last active March 10, 2016 01:37
Mapathon edits

Useful query for mapathon edits.

Original query: http://overpass-turbo.eu/s/eTp

/*
Overpass Turbo Query for edits made during mapathons, and similar activities.

*/
@govvin
govvin / otq_area_mappers.md
Created March 8, 2016 03:03
mappers around a certain geographic coordinate
/**/
[out:csv(::user, ::uid)]
//[out:json][timeout:25]
[diff:"2016-02-22T00:00:00+8","2016-03-06T23:59:59+8"];

// adjust the search radius (in meters) here
{{radius=3000}}
@govvin
govvin / otq_buildings_by_province.md
Created March 3, 2016 04:41
Count all buildings within a province

#Overpass Turbo Query Count all buildings within a province.

See: http://overpass-turbo.eu/s/eKL

/*count buildings by province*/

[out:csv(::"type",::"id", name, admin_level,::"count")];