[R-sig-Geo] Put polygon points in correct order

2009-10-02 Thread Nicholas Lewin-Koh
computing the convex hull and project points onto the closest edge (perpendicular distance), that would give you an ordering but it would be approximate. Nicholas > Message: 6 > Date: Thu, 1 Oct 2009 21:52:33 -0700 > From: Don MacQueen > Subject: [R-sig-Geo] Put polygon points in correc

Re: [R-sig-Geo] Put polygon points in correct order

2009-10-02 Thread Barry Rowlingson
On Fri, Oct 2, 2009 at 5:52 AM, Don MacQueen wrote: > I have a set of points that form a polygon, except that they are in the > wrong order. For example, source into R the object "tmpsub" given below. > Then do > > plot(tmpsub) > polygon(tmpsub) > > You will see that although the points define a p

[R-sig-Geo] Put polygon points in correct order

2009-10-01 Thread Don MacQueen
I have a set of points that form a polygon, except that they are in the wrong order. For example, source into R the object "tmpsub" given below. Then do plot(tmpsub) polygon(tmpsub) You will see that although the points define a polygon, they are in the wrong order. I need an algorithm to p