[R-sig-Geo] a function to calculate distance

Paul Hiemstra p.hiemstra at geo.uu.nl
Tue Mar 2 16:19:04 CET 2010


Mehdi Khaneboubi wrote:
> Hi,
>
> i am new to this list and i have a novice question.
>
> I am trying to calculate distance between two points. I have the latitude
> and longitude of those two points.
>
> I have try with the gdist() function from package Imap but it seems to be
> unsure. is there any others functions in others packages that will be able
> to do it ?
>
> best regards
>
> Mehdi Khaneboubi
>
> 	[[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>   
Hi,

Look at the spDists and spDistsN1 functions from the sp-package.

cheers,
Paul

-- 
Drs. Paul Hiemstra
Department of Physical Geography
Faculty of Geosciences
University of Utrecht
Heidelberglaan 2
P.O. Box 80.115
3508 TC Utrecht
Phone:  +3130 274 3113 Mon-Tue
Phone:  +3130 253 5773 Wed-Fri
http://intamap.geo.uu.nl/~paul



More information about the R-sig-Geo mailing list