Skip to content

geom_nodes() not sizing by nodal attributes #60

Description

@EvanUp

geom_nodes() doesn't seem to be sizing nodes properly when its fed sizes that are related to node attributes.

## repex
data(flo)
n <- network(flo, directed = FALSE)
n%v%'labels' = paste(n%v%'vertex.names', sna::degree(n))

# each time i run this the size of each node changes
ggplot(n, aes(x, y, xend = xend, yend = yend)) +
  geom_edges(colour = "steelblue") +
  geom_nodes(size = degree(n), shape = 21, colour = "steelblue", fill = "white") +
  geom_nodetext(aes(label = labels))+
  theme_blank()

Plot_Zoom

P.S. thank you for creating and sharing this package. It's my favorite network visualization tool.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions