[R] It This data viz possible in R?

Barry Rowlingson b.rowlingson at lancaster.ac.uk
Wed Apr 7 15:46:10 CEST 2010

On Wed, Apr 7, 2010 at 2:28 PM, Brock Tibert <btibert3 at yahoo.com> wrote:
> Hi All,
> I am new to R, but it has been a lot of fun learning as I go and have been blow away by what it can do.  Came across this example and wanted to see if ggplot2 or some other visualization package could make this sort of graphic.
> http://www.visualcomplexity.com/vc/project.cfm?id=717&utm_source=feedburner&utm_medium=feed&utm_campaign=Feed:+visualcomplexity+(visualcomplexity.com)&utm_content=Google+Reader
> Thanks in advance!

 Not quite out-of-the box, but you can draw text with the text()
function setting the angle with the 'srt' parameter, and you can draw
lines using 'lines'. You can compute angles using 'pi'. You'll need a
bit of trig to work out the angle that the lines start and end at.
That's about all you need to know.

 Some of the subtleties of the typesetting of that specific piece may
be tricky, but it's easy to write a function that takes a vector of
strings and an adjacency matrix and plots something like it.

 Give R-help another hour and I reckon something will turn up. Not
from me, I'm watching the IPL cricket.


More information about the R-help mailing list