Questions tagged [distance]

The measure of separation between two entities or locations that may or may not be connected, such as two points.

Filter by
Sorted by
Tagged with
5
votes
0answers
409 views

Converting a distance to a map distance

I have a point and a polyline. I need to find the perpendicular distance between each segment of the polyline and the point. By each segment of the polyline I mean that, each polyline may contain more ...
5
votes
1answer
3k views

Getting result in metric from QGIS Distance Matrix tool in QGIS? [closed]

I'm trying to calculate the distance between points in layer with distance matrix tool. And keep getting strange results no matter what. Like this MASTER ------------SLAVE ---------------- DISTANCE ...
4
votes
3answers
12k views

Creating buffer circle x kilometers from point using Python?

I am wanting to create a circle with an inputted radius around a point of predetermined latitude and longitude. I've been trying to use the formula found in this post which uses an algorithm ...
4
votes
3answers
8k views

How do I determine the center point of several features in OpenLayers?

I have several polygons being drawn on a map, usually representing a country or province or state. Depending on some chosen data, different regions may be selected, so what I was hoping is that there'...
4
votes
2answers
5k views

ST_Distance versus ST_DistanceSpheroid?

As my client software uses lat/lon coordinates when communicating with my (spherical mercator) postgis database i decided to ST_Transform every geometry to WGS-84. However i noticed that ST_Distance ...
4
votes
3answers
2k views

Why is sum of st_length() of segments 20% too big?

I'm running a query to return the total length of some bike paths, from OpenStreetMap. Compared to the known actual length of these paths, they're all a bit too big - something like 10-30%. I know it ...
4
votes
3answers
6k views

How can I calculate the distances between my points in sequence automatically?

I am trying to measure distances between points and writing the calculated measure between these points in the attribute table. The points represents a vehicle's location based on GPS data according ...
4
votes
4answers
2k views

Understanding strange measure distance results from QGIS?

My colleague just told me about incorrect measure distance tool results in QGIS. For reference we used this pond. While our local map provider Mapy.cz and Google Maps: both show about 970 meters ...
4
votes
2answers
4k views

Postgis, get the points that are x meters near another point, in meters

I'm trying to find the points within a certain distance, in meters, from another point. I'm using the function ST_Buffer, but I don't get how to express the distance in meters. I'm trying with ...
4
votes
1answer
13k views

Check if point is within radius of another point with Shapely

I've successfully used Shapely with python to check if a point is within one of a set of polygons in a .shp file but now would like to check if a point is within a circle of radius x miles from ...
4
votes
3answers
2k views

Measure distances between specific features in QGIS for Desktop

I'm completely new using PyQGIS and developing plugins. Currently I have a layer with the X and Y coordinates of electric distribution poles, where each pole is a feature. What I need to do is ...
4
votes
2answers
21k views

How to calculate pixels per meter ratio, according to Google or Bing map zoom level?

I have an image and detect two points in the image. I want to calculate the distance between these two points. I'm using Google map and Bing map. I have x,y pixel values for both two points zoom ...
4
votes
2answers
8k views

Calculate distance in kilometers between two points

I have a few questions regarding the calculation of the distance between 2 postal codes. Take a look at the following code. ### # load the different packages we need ### require("rgdal") require("...
4
votes
1answer
2k views

How to use/interpret/visualise a distance matrix with unknown coordinates?

How would you go about using a distance matrix where points have no coordinates, i.e. what useful statistics can be made and how to visualise it in some useful way?
4
votes
4answers
5k views

Using a list of geographic locations, and determining the X closest locations to a user-defined location

I've got a list of geographical locations in an Excel spreadsheet. I want users to be able to search for a user-defined location, and then have the X number of closest locations from the list pulled ...
4
votes
1answer
4k views

QGIS Python Distance between points [closed]

I'm new in QGIS and in GIS. I want to calculate distance between two points in meters using WGS 84 coordinates. I'm working with QGIS 2.0.1 Dufour and Python 2.7 The code is the following (based on ...
4
votes
2answers
11k views

Calculating distance between set of points: lat and long in R?

I have shapefiles containing the location of several individuals along several months. Positions were documented with a 30 minutes interval. Tables contain the following data fields: collar (ID), ...
4
votes
1answer
10k views

Getting shortest distances between features on separate polygon layers using ArcGIS Desktop?

I have a county-level map for the state of North Carolina, U.S. I would like to compute the shortest distance of each county to any point along the border of Georgia. How would this be done? ...
4
votes
2answers
5k views

tool to find the routing distance between two latitude/longitude points using OSM data

I need a tool to find the distance between two points whose longitude and latitude are given. I am making an application so it will require bulk queries, so i cannot use google maps distance matrix ...
4
votes
1answer
1k views

Hex grid on EPSG:4326 globe (for use in Leaflet)

I'm looking for a way to evenly distribute a hexagon grid (x,y,z) on the EPSG:4326 globe. Knowing this is not mathematically possible I'm accepting the following limitations: Poles don't need ...
4
votes
2answers
2k views

Calculating the distance between points and multiple lines?

I have a point shapefile of about 100 points and a polyline shapefile of about 200 lines and I am interested in finding the distance between every point and each individual polyline. My polyline ...
4
votes
1answer
8k views

Calculate distance between X/Y coordinates by individual in R

In R, I'd like to calculate the straight-line distance between each capture of an animal in my dataset - no need to take into account the curvature of the earth. I have a dataset that looks like this:...
4
votes
2answers
2k views

GeoDjango Order by distance for Model that is linked to User who has a location on their user profile

I need to order my query model by distance, however the point field in question is not on the model class but on the user profile and the i am getting an error when attempting the following. g = ...
4
votes
2answers
451 views

Total newbie. Creating map from aerial photo of golf course in QGIS

I have a aerial photo in tif with a tfw file of the golf course that I work at. I would like to create vector data of different features on the course such as greens fairways tees, etc. to calculate ...
4
votes
2answers
113 views

Measure shortest distance between all points in a layer and a polygon's border line

How do I measure the distance between all points in a vector layer and a polygon (not to the polygon centroid, but to it's border line)? In the image points are fires and the polygon is a National ...
4
votes
1answer
816 views

Calculating distance from point to polyline

I am using ArcMap 10.4.1 - Basic use. I have to determine for each point (leak), how many lines (pipes) there are within a certain distance (Spatial join - within a distance of). Then I have to ...
4
votes
2answers
2k views

Calculate distance of points - SpatialPoints object - along a path - SpatialLines object - using R

I have a SpatialPoints object and a SpatialLines object. I want to calculate all the distances from the start point (first coordinate of the SpatialLines object) to every point in the SpatialPoints ...
4
votes
1answer
2k views

inaccurate distance measurements in Python

I've tried several ways of measuring the distance between two points in my Django application and comparing the results to a reliable measurement. My numbers are way off. For example, I'm assuming the ...
4
votes
3answers
4k views

How to properly utilize DWITHIN Spatial Filter in OpenLayers

Given the following code: var points = []; points.push(new OpenLayers.Geometry.Point(-110, 38)); points.push(new OpenLayers.Geometry.Point(-108, 40)); var lineString = ...
4
votes
1answer
581 views

No difference between distances measured in projected and non-projected data

I'm performing measurements of distances in Km between a lot of localities by using the "Point Distance" in ArcGis 9.3. I realized that the results obtained after using projected coordinate system are ...
4
votes
1answer
130 views

Linear referencing to calculate maximum distance between points by group along line (river system) using ArcGIS Pro

I am using ArcGIS Pro. I have a series of points representing animal locations that were tracked in a small stream. I would like to get the distance between the most upstream and downstream location ...
4
votes
1answer
113 views

Distances in Google Earth Pro

When I use the ruler tool and create a segment between two points, which one of the following is true for the calculated distance?: The geodesic distance calculated over a an ellipsoid The projection ...
4
votes
2answers
506 views

Problem with distance in QGIS

I start a new project with base on OpenLayers plugin but if I check the distance on QGIS with distance tool (I choose a straight road) I view 5.466m on QGIS and 4.300m on google (by walking). How is ...
4
votes
1answer
752 views

What is an efficient Algorithm to draw a straight line from points?

I have some cross section survey data, which is like this: X Y Z pt_dt 2970969.635 359725.0088 83.4242 1-x 2970968.278 359722.2182 83.2591 1-x 2970941.771 359670.127 83.0655 1-x 2970961.369 359708....
4
votes
1answer
4k views

QGIS distance from points to nearest line

How can I get the distances from each point at a shapefile to the nearest line from another? I've tried to follow the directions from Measuring the distance between lines and points in QGIS and ...
4
votes
3answers
2k views

Clustering points in postgresql to create contour map

UPDATE: To try to make this a little more simple, is it possible to create a query which selects a group of points such that each point in the group is at most X units away from at least one other ...
4
votes
2answers
124 views

Average Proximity Metric

I'm looking for a metric that gets at average distance to a given feature. For example, for a point in the water, how far, on average, is the land or to what extent is the point surrounded by land. ...
4
votes
2answers
2k views

Variation of algorithms to find point from another point with bearing and distance

There are several algorithms to calculate distance between two latitude/longitude points. Haversine Hubeny Lambert-Andoyer Vincenty's formulae for inverse problem But there are not so many ...
4
votes
3answers
2k views

Finding average distance within polygon to point?

For my purposes, I can assume a homogeneous distribution of points within the polygon. What I want to find is the average distance from points within a polygon to a specified point. I don't know where ...
4
votes
2answers
8k views

Distance calculation : Integrating incremental gps data

I am trying to build a GPS based odometer based on android. Currently , I am calculating incremental distance changes very frequently ( < 5 meter movement). The distance calculation in android is ...
4
votes
2answers
649 views

Distance Calculation Output Does Not Identify Input Points?

I'm using ArcMap 10 to do distance calculations between a large set of points, using the point distance calculator. The output table generated gives me distances correctly, but the output categories ...
4
votes
3answers
3k views

Comparing two point shapefiles that contain lat/longs and compute distance using ArcGIS Desktop?

I have 2 sets of point shapefiles in ArcGIS Desktop (group A and B), each set has around 1000 entries that contain lat/long. What I want to do is compare Group A against Group B and figure out for ...
4
votes
1answer
287 views

Match linestrings using Fréchet distance

I have two datasets of roads (both in WGS84). One has nicely digitized geometries, but lack some of the attributes and the other has heeded attributes, but digitized terribly. I want to transfer ...
4
votes
1answer
331 views

QGIS distance from a cell center to the nearest point

I am trying to run the following analysis in QGIS 3.2. My inputs: raster layer (with population estimates from LandScan) vector layer, with points (each point represent the location of a mobile cell ...
4
votes
3answers
776 views

Calculating maximum distance between two polygons in meters using ArcMap?

I have two different shapefiles formed by polygons and I need to calculate the max distance of one polygon to the perimeter of the polygon of the other file. I need the output in meters! The first ...
4
votes
1answer
2k views

point to point distances along road network

I have 2 different point layers that I want to use as origins (Company offices) and a separate layer with 500+ points in it (Client Stores) I also have a road network layer. For each of the 500+ ...
4
votes
1answer
9k views

Longitude difference to Meters

I have been trying to find an effective method (be it an equation or table filled with values) that would be useful for converting differences in longitude values into a distance in kilometers. It ...
4
votes
1answer
3k views

Measure distance between points along a line in QGIS

I have a road network and different points connected to the roads. I would like to measure the distance between several points along the roads. Basically I want to do the same like the road graph ...
4
votes
1answer
534 views

Buffer from Point or Polygon with Information from Raster

The intent of this work is to define a buffer around a point or polygon based on information from a raster. For instance if a polygon representing a city and the raster defines how long it takes to ...
4
votes
1answer
211 views

PostGIS point distance from polygon not 0 when on edge

I have a pretty simple problem: SELECT * FROM ST_Distance(ST_GeographyFromText('POLYGON((70 -40,70 -39,71 -39,71 -40,70 -40))'), ST_GeographyFromText('POINT(70.48 -39)'), False) returns 118....

1
3 4
5
6 7
26