Wikipedia:Creating shape maps from OpenStreetMap data: Difference between revisions

Content deleted Content added
No edit summary
No edit summary
Line 7:
 
=== Method 1: Using the OpenStreetMap website ===
[[File:Transport OSM map.jpg|thumb|upright=1.8|The 'Transport Map' layer, when sufficiently zoomed-in, shows routes and route numbers in redshapes]]
#Go to [https://www.openstreetmap.org/ OpenStreetMap] and zoom into the general area where the routeshape runsis.
#Now you should see allmany the transit routes highlightedshapes on the map,. with numbers indicatingIf the routeshape numbers.is Selectnot aimmediately routevisible, bytry right-clicking (control-click on Macs) and selecting 'Query features'.
#Switch to the "Transport Map" layer using the [[File:Antu dialog-layers.svg|22px|link=]] 'Layers' sidebar on the right.
#Then search through the list for the routeshape you desire; selecting it will bring you the relation representing the routeshape, with the routeshape displayed beside it on the map.
#Now you should see all the transit routes highlighted on the map, with numbers indicating the route numbers. Select a route by right-clicking (control-click on Macs) and selecting 'Query features'.
#Then search through the list for the route you desire; selecting it will bring you the relation representing the route, with the route displayed beside it on the map.
 
=== Method 2: Using the OSM Relation Analyzer ===
Line 27 ⟶ 26:
== Part 2: Creating the shape ==
 
== Part 3: Embedding the routeshape into an article ==
{{maplink|frame=yes|frame-width=180|id=Q126163|type=line|stroke-width=2|stroke-color=#00933C|text=[[New York City Subway]] {{NYCS|4}} train}}
There are two ways to embed the routeshape into an article, both using the {{tl|maplink}} template:
 
=== Method 1: Using Wikidata ===
If the routeshape has a Wikidata item and the OpenStreetMap routeshape relation already has a <code>wikidata</code> tag set to that item's QID, you can embed a map of the routeshape directly onto a Wikipedia article as [[mw:Help:Extension:Kartographer#External data|external data]]. Use the {{tl|maplink}} template, setting the {{para|id}} parameter to the QID, such as <kbd>Q88466277</kbd>. Normally, changes to the route in OpenStreetMap are reflected in the article within about two days.
 
Example: <code><nowiki>{{maplink|frame=yes|frame-width=180|id=Q126163|type=line|zoom=10|stroke-width=2|stroke-color=#00933C|text=[[New York City Subway]] {{NYCS|4}} train}}</nowiki></code>
Line 54 ⟶ 53:
Example: <code><nowiki>{{maplink|frame=yes|frame-width=180|frame-height=270|from=COTA8.map|type=line|stroke-width=2|stroke-color=#0e2c6c|text=[[Central Ohio Transit Authority|COTA]] route {{COTA link|8}}}}</nowiki></code>
 
If the routeshape changes in OpenStreetMap, repeat steps 1 through 3 to update the existing Wikimedia Commons map data page.
 
== See also ==