2

I need to calculate the distance of villages ( villages as points) from a border. I have a shapefile containing the locations of villages and another one containing the border. On QGIS, I ran the 'distance to nearest hub' command to calculate the distances. The distances that the command returned looks absurd. Can anyone help to locate where potentially am I going wrong? (I have checked that both the layers are in the same coordinate reference system.)

  • 1
    In which CRS is your data? Why the results seem to be absurd? – Gerardo Jimenez Oct 31 '14 at 14:17
  • 1
    I think the results are in decimal degrees since the crs of your layer is lat-lon. Try reprojecting your layers to a crs that uses meters (for instance) as the measuring units of the coordinates. Try a UTM CRS of the area of your data, for instance – Gerardo Jimenez Oct 31 '14 at 16:41
  • 1
    Did you reproject your data by saving as a new shape file? Usually people tend to think that changing the crs in the layer's properties reproject the data. To do it correctly you have to select the layer and choose save as. In the dialog box you have to define a new name and the new coordinate system – Gerardo Jimenez Oct 31 '14 at 18:54
  • 1
    May be this can help you gis.stackexchange.com/questions/28038/… – Gerardo Jimenez Nov 3 '14 at 14:58
  • 1
    This can be usfeful but you have to convert the line to pints first qgistutorials.com/en/docs/nearest_neighbor_analysis.html – Gerardo Jimenez Nov 3 '14 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.