我有一些单独的GeoJSON对象,例如
var fc = {
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {
"time": 1369786338000
},
"geometry": {
"type": "Point",
"coordinates": [19.026432, 47.49134]
}
}, {
"type": "Feature",
"properties": {
"time": 1369786340000
},
"geometry": {
"type": "Point",
"coordinates": [19.074497, 47.509548]
}
}
]
};
如何将它组合起来制作类似
的内容var combine = {
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {
"time": [
1369786338000,
1369786340000
]
},
"geometry": {
"type": "MultiPoint",
"coordinates": [
[19.026432, 47.49134],
[19.074497, 47.509548]
]
我正在尝试使用turf-combine,但我收到了错误,例如
turf.combine is not a function
当我尝试将GeoJSON组合在一起时。 我已经定义了我的草皮,例如
var turf = require('turf-combine')
谢谢