I am plotting in igraph and having difficulty plotting with an attribute for node size.
I have tried to add size attribute data from a csv file and indicate that it only applies to one column of my edgelist (I have a separate attribute file for the other column of the edgelist). But when I attempt to plot, I get an error message.
Edgelist data:
el[,"org"]=as.character(el[,"org"])
el[,"office"]=as.character(el[,"office"])
el=as.matrix(el)
g=graph.edgelist(el[,1:2])
Attribute for size:
V(g)$cont_amt=as.numeric(b$cont_amt[match(V(g)$name,b$org)])
V(g)$size=V(g)$cont_amt
V(g)$size <- ifelse(V(g)$size %in% el[,1], V(g)$size, NA)
Attempting to plot:
plot(g, layout=m, edge.arrow.size=.2, vertex.label.font=1,
vertex.label.cex=.9, vertex.label.color="black")
I have been getting this error message when I plot: Error in plot.window(...) : need finite 'xlim' values