Message-ID: <CAJMZ3ceBmehpyMUMTiKYGaG97OT2-Q=nBs3X7uiAg4zNfx896g@mail.gmail.com>
Date: 2013-11-14T18:03:35Z
From: email
Subject: polygon circling a graph
Hi:
I want to create a polygon encircling a graph. For this i use convex
hull to get the coordinate points for polygon.
g <- barabasi.game(10)
L<-layout.fruchterman.reingold(g)
temp1 <- chull(L)
temp1 <- c(temp1, temp1[1])
plot(g, layout=layout.fruchterman.reingold)
But when i plot the polygon with the code below, the polygon dosen't
encircle the graph.
polygon(L[temp1, ], col = "#0000FFAA")
How can I plot a polygon circling a graph?
Regards:
John