mirror of
https://github.com/felt/tippecanoe.git
synced 2026-10-02 16:35:40 +02:00
Add point_count_abbreviated property to clustered features (#74)
* Add `point_count_abbreviated` property to clustered features * Update tests and changelog --------- Co-authored-by: Aurele Nitoref <aurele.nitoref@icloud.com>
This commit is contained in:
co-authored by
Aurele Nitoref
parent
7371072e45
commit
3d714e32b0
@@ -4,7 +4,7 @@
|
||||
"description": "tests/loop/out/-z0_-O200_--cluster-densest-as-needed.json.check.mbtiles",
|
||||
"format": "pbf",
|
||||
"generator_options": "./tippecanoe -q -a@ -f -o tests/loop/out/-z0_-O200_--cluster-densest-as-needed.json.check.mbtiles -z0 -O200 --cluster-densest-as-needed tests/loop/in.json",
|
||||
"json": "{\"vector_layers\":[{\"id\":\"in\",\"description\":\"\",\"minzoom\":0,\"maxzoom\":0,\"fields\":{\"clustered\":\"Boolean\",\"point_count\":\"Number\",\"sqrt_point_count\":\"Number\"}}],\"tilestats\":{\"layerCount\":1,\"layers\":[{\"layer\":\"in\",\"count\":1000,\"geometry\":\"Point\",\"attributeCount\":3,\"attributes\":[{\"attribute\":\"clustered\",\"count\":1,\"type\":\"boolean\",\"values\":[true]},{\"attribute\":\"point_count\",\"count\":1,\"type\":\"number\",\"values\":[1000],\"min\":1000,\"max\":1000},{\"attribute\":\"sqrt_point_count\",\"count\":1,\"type\":\"number\",\"values\":[31.620000],\"min\":31.62,\"max\":31.62}]}]}}",
|
||||
"json": "{\"vector_layers\":[{\"id\":\"in\",\"description\":\"\",\"minzoom\":0,\"maxzoom\":0,\"fields\":{\"clustered\":\"Boolean\",\"point_count\":\"Number\",\"point_count_abbreviated\":\"String\",\"sqrt_point_count\":\"Number\"}}],\"tilestats\":{\"layerCount\":1,\"layers\":[{\"layer\":\"in\",\"count\":1000,\"geometry\":\"Point\",\"attributeCount\":4,\"attributes\":[{\"attribute\":\"clustered\",\"count\":1,\"type\":\"boolean\",\"values\":[true]},{\"attribute\":\"point_count\",\"count\":1,\"type\":\"number\",\"values\":[1000],\"min\":1000,\"max\":1000},{\"attribute\":\"point_count_abbreviated\",\"count\":1,\"type\":\"string\",\"values\":[\"1.0k\"]},{\"attribute\":\"sqrt_point_count\",\"count\":1,\"type\":\"number\",\"values\":[31.620000],\"min\":31.62,\"max\":31.62}]}]}}",
|
||||
"maxzoom": "0",
|
||||
"minzoom": "0",
|
||||
"name": "tests/loop/out/-z0_-O200_--cluster-densest-as-needed.json.check.mbtiles",
|
||||
@@ -14,7 +14,7 @@
|
||||
}, "features": [
|
||||
{ "type": "FeatureCollection", "properties": { "zoom": 0, "x": 0, "y": 0 }, "features": [
|
||||
{ "type": "FeatureCollection", "properties": { "layer": "in", "version": 2, "extent": 4096 }, "features": [
|
||||
{ "type": "Feature", "properties": { "clustered": true, "point_count": 1000, "sqrt_point_count": 31.62 }, "geometry": { "type": "Point", "coordinates": [ 0.966797, 0.966751 ] } }
|
||||
{ "type": "Feature", "properties": { "clustered": true, "point_count": 1000, "sqrt_point_count": 31.62, "point_count_abbreviated": "1.0k" }, "geometry": { "type": "Point", "coordinates": [ 0.966797, 0.966751 ] } }
|
||||
] }
|
||||
] }
|
||||
] }
|
||||
|
||||
Reference in New Issue
Block a user