When I digitize a polygon and snap to existing features, sometimes the coordinates end up very slightly away from where I want them to be for example 15.000000099, rather than 16.
Is there a way to round each vertex to a fixed precision?
THIS WILL OVERWRITE YOUR DATA (MAKE A COPY)
That's easy:
Field Calculator
.geom_from_wkt(geom_to_wkt(@geometry, 0))
0
with precision you need.Update existing field
.<geometry>
as a field.OK
.-parameters ---->before ------->after
Another example with point:
P.S. This can collapse your polygons to a point or line, so choose precision wisely.
Changelog for QGIS 2.14 2016-02-26
: qgis.org/project/visual-changelogs/visualchangelog214/…
Commented
Aug 20 at 19:22
You can use the "Snap points to grid" (native:snappointstogrid
) processing algorithm https://docs.qgis.org/3.34/en/docs/user_manual/processing_algs/qgis/vectorgeometry.html#snap-points-to-grid
15
):for example 15.000000099, rather than 16
.