Testing turf.buffer accuracy
See original GitHub issueI am getting a rather large difference comparing turf.buffer to the result of a buffer generated in GIS software. The GIS buffer was projected in MD state plane, then queried to a geoJson feature using SR 4326 via esri’s REST api. Using a leaflet measure tool to ground truth, the GIS buffer was accurate. Does anyone have a good explanation?
var point = turf.point([-76.675801, 38.935749]);
var buffered = turf.buffer(point, 10, {units: 'miles'});
Issue Analytics
- State:
- Created 6 years ago
- Comments:10 (4 by maintainers)
Top Results From Across the Web
Advanced geospatial analysis - Turf.js
Calculates a buffer for input features for a given radius. Units supported are miles, kilometers, and degrees. Arguments. Argument, Type, Description. geojson ...
Read more >Turf.js buffer distance not accurate - GIS Stack Exchange
I'm facing a strange behavior using buffers in Turf. js. When trying to do a 50m buffer around a point, the result is...
Read more >Turf Tips: Soil Testing | Blog - Pioneer Athletics
Remove the vegetation from the sample before mixing the samples. Collect anywhere from 10-15 for an accurate representation of your field.
Read more >Liming Turfgrass Areas - Penn State Extension
Liming Turfgrass Areas. Soil acidity is determined by a soil test, however, not all soil tests provide accurate information on how much lime ......
Read more >Turf and Ornamental Soil Analysis - Spectrum Analytic
And with so much at stake, your test must be as accurate as possible. ... Soil pH; Buffer pH (when needed); Organic Matter;...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks @rowanwins
I think passing a spatial reference code as an option would be very helpful for the buffer and probably some other methods too. I would argue, if turf’s philosophy is to ‘just work as expected’, using proper spatial reference is vitally important to that expectation of working.
Mid latitude buffers will be off by 25% and running turf.circle will give a more accurate result in these parts of the globe.
If turf has the goal of being the geoprocessing engine of the future, which I hope it does, it can’t have inaccuracies this large and be used in serious GIS applications. Thanks again for your help and good work with Turf!
@SteveCline @JamesLMilner Trying to help clean up some older issues here: Similar to issues #1470, #1484, #1547 this issue has been fixed with Turf >v6.2.0.
Here’s a small notebook showcasing Turf’s buffer operation on the point and 10 mile buffer radius presented in @SteveCline’s original question for both Turf v6.5.0 and v5.1.6. The buffer is compared to a buffer calculated using GeoPandas (link to Jupyter notebook used for the calculation.
https://observablehq.com/@chrispahm/turf-issue-1246
Since the difference is arguably small, I guess this issue can be closed as well!