Flexibly outlining a set of points with alphahull
We’ve previously covered the convex hull here at is.R(), and in that post I admitted that I was somewhat hard-pressed to come up with a common use-case — at least for Political Science applications.
Well, today’s Gist illustrates the use of something even cooler than the convex hull, in fact it’s the generalization of the convex hull: the alpha hull, as implemented in the alphahull package.
By altering the alpha parameter, you can change the “sensitivity” of the outlining, which is based on a Delaunay triangulation / Voronoi tesselation, which can be seen when plotting an alpha hull object.
To leave a comment
for the author, please follow the link and comment on his blog: is.R()
offers daily e-mail updates
news and tutorials
on topics such as: visualization (ggplot2
), programming (RStudio
, Web Scraping
) statistics (regression
, time series
) and more...
If you got this far, why not subscribe for updates
from the site? Choose your flavor: e-mail
, or facebook