Skip to content

Disturbed layout in subgraph #775

Description

@clpippel
  • Consider the code below.
## bug / undesired / unexpected behaviour.
g        <- make_ring(10)
g$layout <- layout_in_circle(g)
sg       <- subgraph(g, c(1,2))
## delete_graph_attr(sg, "layout")
plot(sg)

Note that vertices 1 and 2 are plotted multiple times.
This is because the layout vector of the original graph is copied to the sub graph.

Version information

  • R/igraph version: [1] igraph_1.4.1

subgraph-layout-bug

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugan unexpected problem or unintended behavior

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions