我正在尝试使用草皮缓冲geojson文件中的所有点。有50分。我的脚本按预期生成并输出geojson文件,但QGIS不会显示生成的geojson文件。我有什么想法吗?
var turf = require('turf');
var fs = require('fs');
var points = JSON.parse(fs.readFileSync('points.geojson')).features;
bufferlist = [];
for (i = 0; i < points.length; i++) {
console.log(i);
buff = turf.buffer((points[i]), .001);
bufferlist.push(buff);
}
var bufferOut = turf.featurecollection(bufferlist);
fs.writeFileSync( "bufferOut.geojson", JSON.stringify(bufferOut));
console.log('Done');
感谢您的任何见解!