I need to add the id attribute to my vertices as labels, and display them in the plot. Which I did with the following code:
V(novel)$label <- V(novel)$id
plot(novel)
However, I only want to display the id of the vertices where the weighted degree is more than 30. I tried the code below, but it gives me only TRUE
or FALSE
as output, instead of filtering the vertices.
graph.strength(novel) > 30
How can I filter in which vertices should the plot display the id?