diff --git a/coverage.html b/coverage.html index 2ce4bc8..bdde104 100644 --- a/coverage.html +++ b/coverage.html @@ -34,5 +34,19 @@

国土交通省国土政策局「国土数値情報 警察署データ(平成24年:2012)2:警察署」をもとにhayashiが編集・加工したものです。

+

+ +

+

OpenStreetMap coverage (国土数値情警察署データ を指標にした網羅率)

+

国土交通省国土政策局「国土数値情報 警察署データ(平成24年:2012)4:交番」をもとにhayashiが編集・加工したものです。

+
+ +

+ +

+

OpenStreetMap coverage (国土数値情警察署データ を指標にした網羅率)

+

国土交通省国土政策局「国土数値情報 警察署データ(平成24年:2012)5:派出所」をもとにhayashiが編集・加工したものです。

+
+ diff --git a/coverage/police4.html b/coverage/police4.html new file mode 100644 index 0000000..f2d2b78 --- /dev/null +++ b/coverage/police4.html @@ -0,0 +1,107 @@ + + + + + + OpenStreetMap coverage (amenity=police) + + + + +
+
+

OpenStreetMap coverage (交番の網羅率)

+
+

+
+ +
+
+ +
+
+

このデータは月に2〜3回程度の頻度で更新を行う予定です。

+
+
+
+ +

国土数値情報の交番位置を中心とする、200m四方の矩形領域に存在するOSMのamenity=policeノードの評価点の合計を数える。
+
+ 対象ノード;
+ node & area: amenity = police
+ node & area: disused:amenity = police
+ node & area: abandoned:amenity = police
+ node & area: demolished:amenity = police
+ node & area: historic:amenity = police
+ node & area: was:amenity = police
+ node & area: removed:amenity = police
+ node & area: no:amenity = police
+
+ 評価点;
+ 'amenity=police'      → 50ポイント
+ 'disused:amenity=police'  → 50ポイント
+ 'abandoned:amenity=police' → 50ポイント
+ 'demolished:amenity=police' → 50ポイント
+ 'historic:amenity=police'  → 50ポイント
+ 'was:amenity=police'    → 50ポイント
+ 'removed:amenity=police'  → 50ポイント
+ 'no:amenity=police'     → 50ポイント
+
+ レベル分け:
+ 評価点の合計値をもとに以下に色分けしています。
+ 0ポイント → 赤 (未入力)
+ 50ポイント以上 → 青 (入力済)
+

+

DEVELOP: SRCも公開. 自由にお使いください

+
+ +
+
+ + + + + + + + + + + + +
マッピングカバー率 都道府県別
code都道府県標本数入力数カバー率(%)
+
+

+
+
+ + + + + + + + diff --git a/coverage/police4.js b/coverage/police4.js new file mode 100644 index 0000000..8b57e54 --- /dev/null +++ b/coverage/police4.js @@ -0,0 +1,50 @@ +var debug = {}; + +var map = L.map('map').setView([36.131, 140.241], 9); // Kasumigaura + +//OSMレイヤー追加 +var osm = L.tileLayer( + 'http://tiles.wmflabs.org/bw-mapnik/{z}/{x}/{y}.png', { + attribution: 'Map data © OpenStreetMap', + maxZoom: 18 + } +); +osm.addTo(map); + +var mvtSource0 = new L.TileLayer.MVTSource({ + url: "./tiles/tilePolice4z/{z}/{x}/{y}.pbf", + style: function (feature) { + var style = {}; + style.color = 'rgba(255,0,0,1)'; + style.radius = 5; + style.selected = { + radius: 6 + }; + return style; + } +}); +map.addLayer(mvtSource0); + +var mvtSource1 = new L.TileLayer.MVTSource({ + url: "./tiles/tilePolice4/{z}/{x}/{y}.pbf", + style: function (feature) { + var style = {}; + style.color = 'rgba(0,255,0,1)'; + style.radius = 5; + style.selected = { + radius: 6 + }; + return style; + } +}); +map.addLayer(mvtSource1); + +//Globals that we can change later. +var fillColor = 'rgba(149,139,255,0.4)'; +var strokeColor = 'rgb(20,20,20)'; + +//Add layer +mvtSource0.addTo(map); +mvtSource1.addTo(map); + +L.control.scale({imperial:false}).addTo(map); diff --git a/coverage/police4M.html b/coverage/police4M.html new file mode 100644 index 0000000..dd5ce5d --- /dev/null +++ b/coverage/police4M.html @@ -0,0 +1,32 @@ + + + + + + OpenStreetMap coverage (amenity=police) + + + + +
+
+

OpenStreetMap coverage (交番の網羅率)

+
+

+
+
+
+ + + + + + + + + diff --git a/coverage/police4M.js b/coverage/police4M.js new file mode 100644 index 0000000..22ff6e0 --- /dev/null +++ b/coverage/police4M.js @@ -0,0 +1,97 @@ +// =================================================================== +var center_lon = 140.241; // 中心の経度(霞ヶ浦) +var center_lat = 36.131; // 中心の緯度(霞ヶ浦) + +var initZoom = 11; // ズームの初期値 +var MinZoom = 6; // ズームの最小値(最も広い範囲) +var MaxZoom = 17; // ズームの最大値(最も狭い範囲) + +var initPrecision = 8; // 座標表示の小数点以下の桁数の初期値 +// ******************************************************************* + +// 表示用の view 変数の定義。 +const view = new ol.View({ + center: ol.proj.fromLonLat([center_lon, center_lat]), + zoom: initZoom, + maxZoom: MaxZoom, + minZoom: MinZoom +}); + +const ort = new ol.layer.Tile({ + source: new ol.source.OSM(), + title: "OpenStreetMap", + visible: true +}); +/* +grayOsmLayer.on('postcompose', function(event) { + grayscale(event.context); +}); +*/ + +const police4z = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + format: new ol.format.MVT(), + url: "./tiles/tilePolice4z/{z}/{x}/{y}.pbf" + }), + title: "Police 0: 未入力", + visible: true, + opacity: 1, + style: function(feature){ + return [ + new ol.style.Style({ + image: new ol.style.Circle({ + radius: 8, + fill: new ol.style.Fill({color: "#ff0000"}) + }) + }) + ]; + } +}); + +const police4 = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + format: new ol.format.MVT(), + url: "./tiles/tilePolice4/{z}/{x}/{y}.pbf" + }), + title: "Police 1: 入力済み", + visible: true, + opacity: 1, + style: function(feature){ + return [ + new ol.style.Style({ + image: new ol.style.Circle({ + radius: 8, + fill: new ol.style.Fill({color: "#00ff00"}) + }) + }) + ]; + } +}); + +var strokestyle = new ol.style.Style({ + stroke: new ol.style.Stroke({ + color: 'rgba(53, 175, 109, 0.7)', + width: 4 + }) +}); + +const mapillary = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + attributions: '© Mapillary', + format: new ol.format.MVT(), + tileGrid: ol.tilegrid.createXYZ({maxZoom: 22}), + tilePixelRatio: 16, + opacity: 0.7, + url: 'https://d25uarhxywzl1j.cloudfront.net/v0.1/{z}/{x}/{y}.mvt' + }), + title: "Mapillary", + visible: true, + style: strokestyle +}); + +const map = new ol.Map({ + target: "map", + controls: ol.control.defaults().extend([new ol.control.ScaleLine()]), + view: view, + layers: [ort, police4z, police4, mapillary] +}); diff --git a/coverage/police5.html b/coverage/police5.html new file mode 100644 index 0000000..773a243 --- /dev/null +++ b/coverage/police5.html @@ -0,0 +1,107 @@ + + + + + + OpenStreetMap coverage (amenity=police) + + + + +
+
+

OpenStreetMap coverage (派出所の網羅率)

+
+

+
+ +
+
+ +
+
+

このデータは月に2〜3回程度の頻度で更新を行う予定です。

+
+
+
+ +

国土数値情報の交番位置を中心とする、200m四方の矩形領域に存在するOSMのamenity=policeノードの評価点の合計を数える。
+
+ 対象ノード;
+ node & area: amenity = police
+ node & area: disused:amenity = police
+ node & area: abandoned:amenity = police
+ node & area: demolished:amenity = police
+ node & area: historic:amenity = police
+ node & area: was:amenity = police
+ node & area: removed:amenity = police
+ node & area: no:amenity = police
+
+ 評価点;
+ 'amenity=police'      → 50ポイント
+ 'disused:amenity=police'  → 50ポイント
+ 'abandoned:amenity=police' → 50ポイント
+ 'demolished:amenity=police' → 50ポイント
+ 'historic:amenity=police'  → 50ポイント
+ 'was:amenity=police'    → 50ポイント
+ 'removed:amenity=police'  → 50ポイント
+ 'no:amenity=police'     → 50ポイント
+
+ レベル分け:
+ 評価点の合計値をもとに以下に色分けしています。
+ 0ポイント → 赤 (未入力)
+ 50ポイント以上 → 青 (入力済)
+

+

DEVELOP: SRCも公開. 自由にお使いください

+
+ +
+
+ + + + + + + + + + + + +
マッピングカバー率 都道府県別
code都道府県標本数入力数カバー率(%)
+
+

+
+
+ + + + + + + + diff --git a/coverage/police5.js b/coverage/police5.js new file mode 100644 index 0000000..1118be1 --- /dev/null +++ b/coverage/police5.js @@ -0,0 +1,50 @@ +var debug = {}; + +var map = L.map('map').setView([36.131, 140.241], 9); // Kasumigaura + +//OSMレイヤー追加 +var osm = L.tileLayer( + 'http://tiles.wmflabs.org/bw-mapnik/{z}/{x}/{y}.png', { + attribution: 'Map data © OpenStreetMap', + maxZoom: 18 + } +); +osm.addTo(map); + +var mvtSource0 = new L.TileLayer.MVTSource({ + url: "./tiles/tilePolice5z/{z}/{x}/{y}.pbf", + style: function (feature) { + var style = {}; + style.color = 'rgba(255,0,0,1)'; + style.radius = 5; + style.selected = { + radius: 6 + }; + return style; + } +}); +map.addLayer(mvtSource0); + +var mvtSource1 = new L.TileLayer.MVTSource({ + url: "./tiles/tilePolice5/{z}/{x}/{y}.pbf", + style: function (feature) { + var style = {}; + style.color = 'rgba(0,255,0,1)'; + style.radius = 5; + style.selected = { + radius: 6 + }; + return style; + } +}); +map.addLayer(mvtSource1); + +//Globals that we can change later. +var fillColor = 'rgba(149,139,255,0.4)'; +var strokeColor = 'rgb(20,20,20)'; + +//Add layer +mvtSource0.addTo(map); +mvtSource1.addTo(map); + +L.control.scale({imperial:false}).addTo(map); diff --git a/coverage/police5M.html b/coverage/police5M.html new file mode 100644 index 0000000..fa1fc0d --- /dev/null +++ b/coverage/police5M.html @@ -0,0 +1,32 @@ + + + + + + OpenStreetMap coverage (amenity=police) + + + + +
+
+

OpenStreetMap coverage (派出所の網羅率)

+
+

+
+
+
+ + + + + + + + + diff --git a/coverage/police5M.js b/coverage/police5M.js new file mode 100644 index 0000000..968ebf0 --- /dev/null +++ b/coverage/police5M.js @@ -0,0 +1,97 @@ +// =================================================================== +var center_lon = 140.241; // 中心の経度(霞ヶ浦) +var center_lat = 36.131; // 中心の緯度(霞ヶ浦) + +var initZoom = 11; // ズームの初期値 +var MinZoom = 6; // ズームの最小値(最も広い範囲) +var MaxZoom = 17; // ズームの最大値(最も狭い範囲) + +var initPrecision = 8; // 座標表示の小数点以下の桁数の初期値 +// ******************************************************************* + +// 表示用の view 変数の定義。 +const view = new ol.View({ + center: ol.proj.fromLonLat([center_lon, center_lat]), + zoom: initZoom, + maxZoom: MaxZoom, + minZoom: MinZoom +}); + +const ort = new ol.layer.Tile({ + source: new ol.source.OSM(), + title: "OpenStreetMap", + visible: true +}); +/* +grayOsmLayer.on('postcompose', function(event) { + grayscale(event.context); +}); +*/ + +const police5z = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + format: new ol.format.MVT(), + url: "./tiles/tilePolice5z/{z}/{x}/{y}.pbf" + }), + title: "Police 0: 未入力", + visible: true, + opacity: 1, + style: function(feature){ + return [ + new ol.style.Style({ + image: new ol.style.Circle({ + radius: 8, + fill: new ol.style.Fill({color: "#ff0000"}) + }) + }) + ]; + } +}); + +const police5 = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + format: new ol.format.MVT(), + url: "./tiles/tilePolice5/{z}/{x}/{y}.pbf" + }), + title: "Police 1: 入力済み", + visible: true, + opacity: 1, + style: function(feature){ + return [ + new ol.style.Style({ + image: new ol.style.Circle({ + radius: 8, + fill: new ol.style.Fill({color: "#00ff00"}) + }) + }) + ]; + } +}); + +var strokestyle = new ol.style.Style({ + stroke: new ol.style.Stroke({ + color: 'rgba(53, 175, 109, 0.7)', + width: 4 + }) +}); + +const mapillary = new ol.layer.VectorTile({ + source: new ol.source.VectorTile({ + attributions: '© Mapillary', + format: new ol.format.MVT(), + tileGrid: ol.tilegrid.createXYZ({maxZoom: 22}), + tilePixelRatio: 16, + opacity: 0.7, + url: 'https://d25uarhxywzl1j.cloudfront.net/v0.1/{z}/{x}/{y}.mvt' + }), + title: "Mapillary", + visible: true, + style: strokestyle +}); + +const map = new ol.Map({ + target: "map", + controls: ol.control.defaults().extend([new ol.control.ScaleLine()]), + view: view, + layers: [ort, police5z, police5, mapillary] +});