Tag Info

Hot answers tagged

3

Assuming that your points are in order, and that this works at 10.0 (I'm using 10.2): Field Calculator Expression: dist( !Shape! ) Field Calculator Code Block: count = 0 def dist(shape): global prev global count point = arcpy.PointGeometry(shape.getPart(0)) if count > 0: distance = point.distanceTo(prev) else: ...


3

Achieving this goal is somewhat a basic task in GIS, however the method in QGIS might not be trivial. Your best chance is to use GRASS's r.walk function, which creates an anisotropic cost surface (dem+slope+other factors). First, you have to create a friction surface as an input to r.walk. In your case it can be a single-valued raster (1.0) matching the ...


2

You can use the Distance Matrix function: (from QGIS 2.2) Vector > Analysis Tools > Distance matrix or select it from Processing Toolbox Select the same point layer and it will calculate the distances between each point. You can then simply scroll or filter out your centre point to see the distances from the centre point to all the others in the layer. ...


1

One way to merge your lines is to use the "integrate" tools. Be carefull when you use this tool because it modifies the input data. If you want to detect those lines, you could use integrate on a copy of your original data, the you run "intersect" between the original and the integrated data : the result will only include the lines that were not moved by ...


1

what do you mean with one query? try to create a command/script using this suggestion: get the geometry for the center feature and use QgsGeometry.distance() method http://qgis.org/api/classQgsGeometry.html#a9971f1e9c56cdf57c06017ec64e70151 looping to all other point geometries regards


1

If you can't get v.distance to work (it should be available through the GRASS plugin), you could try the NNJoin plugin that I uploaded to the QGIS plugin repository recently. The NNJoin plugin does not use spatial indexes for line layers, so it is not practical if you have large datasets.


1

Both answers from @HåvardTveite and @mapBaker should help you get your results. What I normally do is first use the Distance to nearest hub tool and then Join the resulting layer with the polygon layer. This is a late answer but anyway, I created 2 simple layers (polygon and point) with the following attributes: I then ran the Distance to nearest hub via ...


1

Using a projected coordinate reference system (e.g. UTM) simplifies things. In GRASS you can use the v.distance function. In QGIS you can use v.distance through the GRASS plugin. If your datasets are small you can use the NNJoin plugin.


1

I found the answers provided here very helpful and came up with a refined version. So, here's another way to accomplish this task, but without having to alter the original table. SELECT t1.gid AS gid_1, t2.gid AS gid_2, ST_Distance(t1.geom, t2.geom) AS mindist FROM table t1, table t2 WHERE t1.gid != t2.gid AND ST_Distance(t1.geom, t2.geom) != 0 ORDER BY ...


1

Other way to measure this, it is using Qchainage (QGis plugin) to produce nodes equallly spaced from line. Then, you may use Distance to nearest hub (QGis plugin) to calculate distance among points.



Only top voted, non community-wiki answers of a minimum length are eligible