igraph-vs-indexing2

0th

Percentile

Select vertices and show their metadata

The double bracket operator can be used on vertex sequences, to print the meta-data (vertex attributes) of the vertices in the sequence.

Usage
## S3 method for class 'igraph.vs':
[[(x, ...)
Arguments
x
A vertex sequence.
...
Additional arguments, passed to [.
Details

Technically, when used with vertex sequences, the double bracket operator does exactly the same as the single bracket operator, but the resulting vertex sequence is printed differently: all attributes of the vertices in the sequence are printed as well.

See [.igraph.vs for more about indexing vertex sequences.

Value

  • The double bracket operator returns another vertex sequence, with meta-data (attribute) printing turned on. See details below.

See Also

Other vertex and edge sequence operations: [.igraph.es, %--%, %->%, %<-%, igraph-es-indexing; [.igraph.vs, igraph-vs-indexing; [[.igraph.es, igraph-es-indexing2; c.igraph.es; c.igraph.vs; difference.igraph.es; difference.igraph.vs; intersection.igraph.es; intersection.igraph.vs; rev.igraph.es; rev.igraph.vs; union.igraph.es; union.igraph.vs; unique.igraph.es; unique.igraph.vs

Other vertex and edge sequences: $.igraph.es, $<-.igraph.es, E<-, [<-.igraph.es, [[<-.igraph.es, igraph-es-attributes, igraph-es-attributes, igraph-es-attributes, igraph-es-attributes, igraph-es-attributes; $.igraph.vs, $<-.igraph.vs, V<-, [<-.igraph.vs, [[<-.igraph.vs, igraph-vs-attributes, igraph-vs-attributes, igraph-vs-attributes, igraph-vs-attributes, igraph-vs-attributes; E; V; [.igraph.es, %--%, %->%, %<-%, igraph-es-indexing; [.igraph.vs, igraph-vs-indexing; [[.igraph.es, igraph-es-indexing2; print.igraph.es; print.igraph.vs

Aliases
  • [[.igraph.vs
  • igraph-vs-indexing2
Examples
g <- make_ring(10) %>%
  set_vertex_attr("color", value = "red") %>%
  set_vertex_attr("name", value = LETTERS[1:10])
V(g)
V(g)[[]]
V(g)[1:5]
V(g)[[1:5]]
Documentation reproduced from package igraph, version 1.0.0, License: GPL (>= 2)

Community examples

Looks like there are no examples yet.