longest distance in a polygon

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

longest distance in a polygon

Roger Bivand
On Mon, 6 Dec 2004, Brian Menounos wrote:

> Hello,
> I'm interested in determining the longest linear distance in an
> irregular polygon (and potentially ones with internal holes) and
> wondering if there is R code to accomplish this? My interest is to
> develop an automated procedure to calculate the effective fetch for
> lakes. In a GIS one can clip line coverage based on an irregular
> boundary to accomplish this task. The PBSmapping function 'clipLines'
> unfortunately only works with rectangles.
> Any help would be greatly appreciated.

I suggest looking at the gpclib package. I don't think the functionality
you need is there at the level of an R function, but you may find that you
can see how the intersect() function for polygons works. The underlying
computational geometry library in both PBSmapping and gpclib is the same.


> Thanks in advance,
> Brian Menounos

Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Breiviksveien 40, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 93 93
e-mail: Roger.Bivand at nhh.no

Roger Bivand
Department of Economics
Norwegian School of Economics
Helleveien 30
N-5045 Bergen, Norway